ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   vba code to cycle through each column in a sheet (https://www.excelbanter.com/excel-programming/311026-vba-code-cycle-through-each-column-sheet.html)

David

vba code to cycle through each column in a sheet
 
Please help.

I have a macro that applies multiple formatting to a column.

Now I want to add looping code so that the formatting will be applied to
each column in the sheet that has data in the first row for the column; when
there is no more data in the first row(when the entire column is blank) I do
not want the column to be formatted.

How to I progammatically determine the number of non-empty columns in a
sheet and then loop through each of these columns?

Thank you.




All times are GMT +1. The time now is 05:34 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com