Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Shared workbooks and code execution

Status
Not open for further replies.

PeteG

Programmer
Feb 23, 2001
144
GB
Hi,
If two people are using a shared workbook and they both carry out a function that executes VBA code in, say, a module of a referenced xla file, do their actions occur completely in isolation of each other? If, for instance, there are public global variables that get set when one person starts the action, might they get reset to something different when the next person starts his?
Many thanks for any help on this one!
 
chances are that something funky will happen

To be honest, your best bet is to not share workbooks unless they are VERY simple

Any complexity = lots of problems with shared workbooks

Rgds, Geoff

We could learn a lot from crayons. Some are sharp, some are pretty and some are dull. Some have weird names and all are different colours but they all live in the same box.

Please read FAQ222-2244 before you ask a question
 
Thanks. Actually, I've had a bit of a test of this and it does seem that each users variables are isolated from each other. Public 'global' variable changes are not seen by any other users (which, thankfully, is what I want!). Any changes by other users to cells referenced in code are only picked up once the user has accepted those changes (rather obviously, I guess).
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top