I need to clear any cell formatting on empty rows at the top/left/bottom/right of a spreadsheet. Only cells with no content but that are formatted (color/borders/etc.) are to be affected. This is to clear cells that may be accidentally formatted many rows down or columns to the right in the spreadsheet, causing potentially many extra empty pages to be printed.
See this image: ExcelFormattedCells.png (6.4 KB)
Here, only the first page contains any data; that is all I want to be printed. The default, in Excel anyway, is to print the 4 pages.
Using Excel I was able to use the Application.WorksheetFunction to use CountA to return me a collection of cells with data; I used that to divide and conquer through the rows until I found where the empty rows ended or started and from there I was able to clear the formatting.
How can I get Aspose to calculate the COUNTA for me - I couldn’t find an match to the Appplication.WorksheetFunction.