Article Details
Id: | 20784 |
Product: | finPOWER Connect |
Type: | NEW |
Version: | 4.00.04 |
Opened: | 13/09/2023 |
Closed: | 31/10/2023 |
Released: | 05/12/2023 |
Job: | J032034 |
Excel Workbook functions; added FreezePanes function to ISExcelWorksheet
A new FreezePanes function has been added to ISExcelWorksheet.
This allows a range of rows and/or columns to be "frozen", i.e. to remain visible when the rest of the worksheet is scrolled. This is typically used for row or column headings.
An example is shown below:
Dim ExcelWorkbook As ISExcelWorkbook
Dim row As Integer
Dim col As Integer
ExcelWorkBook = finBL.CreateExcelWorkbook
With ExcelWorkBook
' Create Worksheet
.Worksheets.Add("Freeze Test")
With .Worksheets(0)
For col = 1 To 10
For row = 1 To 20
.Cell(col, row).SetString(String.Format("C{0} R{1}", col, row))
Next
Next
' Freeze the top row
If Not .FreezePanes(1, 0) Then
finBL.DebugPrint(finBL.Error.Message)
End If
End With
End With