![]() |
Global variable
Is there any way to have the same variable available to a
worksheet function (e.g. button_click) and a sub procedure in a code module. I need to have the same variable (an index in a for loop) available to both. Any thoughts? |
Global variable
Declare the variable publicly (preferrably at the top of a ) module, like...
Public gvVariable as Variant or Global gvVariable as Variant -- _______________________ Robert Rosenberg R-COR Consulting Services Microsoft MVP - Excel "Don" wrote in message ... Is there any way to have the same variable available to a worksheet function (e.g. button_click) and a sub procedure in a code module. I need to have the same variable (an index in a for loop) available to both. Any thoughts? |
All times are GMT +1. The time now is 02:21 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com