JeffT
02-06-2011, 03:57 AM
Hi sorry to ask this which is probably quite simple but its been a couple of years since I have done any VBA.
programming
In column A on sheet 1 there is a list of numbers 1 at the top & the maximum at the bottom of the list.
The numbers are not in consecutive rows e.g 1 is always in A:3 2 could be A:10 , 3 A:19 etc.
I just want to find the maximum number in column A so this can be used as a counter in the rest of the code which works.
I imagine its simple but I've tried lots of things but it doesn't quite work. I can do it simply in the spreadsheet e.g. =MAX(A:A) then refer to that cell but I'd rather just find it with the code.
Thanks
Jeff
programming
In column A on sheet 1 there is a list of numbers 1 at the top & the maximum at the bottom of the list.
The numbers are not in consecutive rows e.g 1 is always in A:3 2 could be A:10 , 3 A:19 etc.
I just want to find the maximum number in column A so this can be used as a counter in the rest of the code which works.
I imagine its simple but I've tried lots of things but it doesn't quite work. I can do it simply in the spreadsheet e.g. =MAX(A:A) then refer to that cell but I'd rather just find it with the code.
Thanks
Jeff