LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #14   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 40
Default Keeping Variables Alive

On 4 Jun, 17:21, Jim Thomlinson <James_Thomlin...@owfg-Re-Move-
This-.com wrote:
Just my two cents but you are using globals for the wrong reason. You are
better off creating the collection when it is needed than trying to keep the
collection stored globally. The code to create the collection is relatively
easy and very quick.


I think you may be confusing the example I created to show some wierd
behaviour of global variables with the actual application that I am
writing. Creating the application object and the dozens of child
objects and checking data validity in the actual application is far
from fast, it can take 10 minutes. It also creates an annoying amount
of disruption in the server application UI while it is doing it too.

What I am doing is using sets of values stored in a set of excel
sheets to set combinations of values in a separate application more
rapidly and accurately than a human can do it. This requires an object
which provides an interface between Excel and the OLE server, and an
array of sub-objects, one for each onscreen variable to be adjusted.
There are 10,000 variables that could be adjusted, though in practice
the users will only be performing experiments on 20 or so at a time.
There is a certain amount of overhead in the interaction, which can be
minimised by creating the interface objects ahead of time. Most of the
"variables" are not simple scalar values, they are 3D maps which the
interface objects allow me to manipulate.

See it as equivalent to not creating an Excel application object and a
Sheets collection every time you want to look at a cell value. I want
a persistent array of objects which I can interrogate and set values
through.
 
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
Keeping Values in Variables Jurrasicway Excel Programming 2 May 27th 06 12:29 PM
keeping a shape constant regardless of changes in variables Osvy Excel Discussion (Misc queries) 0 March 28th 06 04:49 AM
Keeping variables in a formula Brian Mann Excel Discussion (Misc queries) 1 September 22nd 05 09:13 PM
Keeping a Variables value alive. Chris W[_3_] Excel Programming 1 March 19th 05 11:54 AM
Keeping track of Global variables Stuart[_5_] Excel Programming 3 July 15th 04 02:14 PM


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

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

About Us

"It's about Microsoft Excel"