"Patrice" <http://www.chez.com/scribe/schrieb im Newsbeitrag
news:ej**************@TK2MSFTNGP03.phx.gbl...
Hard to say more as we don"t know what it is about...
Thanks a lot for the answer. I can give you some more information. Maybe the
task is clearer then.
The DLL offers some classes. Each of these classes offers several methods.
Each of these methods needs basic data. Maybe it is data that is read from a
database or from a configuration XML file.
I do not want to read the basic data on each an every method call. The DLL
should read the data once and store it internally.
This might be solved by an extra method, which reads the basic data, stores
it in some objects, and returns it to the caller. The caller would then hand
over this data to each of the method calls. Something like
Dim oBaseData As DLL.BaseData
Dim oWorker As DLL.Worker
oWorker = New DLL.Worker
oBaseData = oWorker.ReadBaseData("server", "database")
oWorker.Calc1(oBaseData, ...)
oWorker.Calc2(oBaseData, ...)
oWorker.Calc3(oBaseData, ...)
So the oBaseData would be passed into the DLL, and then also from one
function to the next function within the DLL.
This is not so nice. Many parameters have to be passed along.
As this is really "global data", I prefered to have a "global variable" and
access that it from each DLL function.
Michael G. Schneider