TonyS
04-16-2007, 06:17 AM
Hi
I have written some vba using absolute cell addresses
eg - If ['Sheet1'!A1] > 25 Then ...
Is it possible to declare a global const at the top of the module instead
eg - Const AgeCell = Worksheets("Sheet1").cells(1, 1)
and then use this code in the Subroutine
eg - If AgeCell > 25 Then ...
However, I've tried declaring with Const, Set & Public but cannot get it to work.
Any ideas?
I have written some vba using absolute cell addresses
eg - If ['Sheet1'!A1] > 25 Then ...
Is it possible to declare a global const at the top of the module instead
eg - Const AgeCell = Worksheets("Sheet1").cells(1, 1)
and then use this code in the Subroutine
eg - If AgeCell > 25 Then ...
However, I've tried declaring with Const, Set & Public but cannot get it to work.
Any ideas?