#1   Report Post  
Posted to microsoft.public.excel.programming
No Name
 
Posts: n/a
Default Variables

Is it possible to set a variable in one module and use it
in another module?
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Variables

set the variables scope to Public and declare it outside of a sub or functions. for example:

at the top of 1 module put
Public MyVariable as integer

you should be good to use it anywhere now.

" wrote:

Is it possible to set a variable in one module and use it
in another module?

  #3   Report Post  
Posted to microsoft.public.excel.programming
No Name
 
Posts: n/a
Default Variables


Thank You!!



-----Original Message-----
set the variables scope to Public and declare it outside

of a sub or functions. for example:

at the top of 1 module put
Public MyVariable as integer

you should be good to use it anywhere now.

" wrote:

Is it possible to set a variable in one module and use

it
in another module?

.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Not at all clear on use of variables and/or object variables JMay-Rke Excel Discussion (Misc queries) 11 July 4th 08 06:36 PM
Too Many Variables Heliocracy Excel Worksheet Functions 6 April 6th 07 07:02 PM
More than 1 Variables [email protected] Excel Discussion (Misc queries) 1 November 29th 06 02:09 AM
Variables in VBA Jeff Excel Discussion (Misc queries) 2 October 17th 06 02:30 PM
Variables richie Excel Programming 1 October 16th 03 06:44 PM


All times are GMT +1. The time now is 09:37 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"