how to write dynamic link library for excel to use?

  • Thread starter Thread starter Desmond Leung
  • Start date Start date
D

Desmond Leung

HI, I tried to use these code, However, I need the
variable
that can be
shared among different modules and different workbooks.
e.g, I have
written an addin workbook : addin.xla and I declared an
array called
arr1() as double.
then I use this array in other sheet to copy the values
into this array
from another workbook book1,xls and I find that it doesn't
work.

may you help me again? thanks


Desmond
-----Original Message-----

as per my later response....using public variables makes
the adta available to other code modules.
If you want the data vailable some other way, you might
consider saving them to a file using the file OPEN method
for reading/writing, ot better, using the
FileSystemObject to access files.

Patrick Molloy
Microsoft Excel MVP


.
..
 
Desmond,

If you want the variables to have a value assigned and then have that value available later to other workbooks, the usual way is to
write the data to a range on a worksheet of the add-in. It will then be available at any time to be read.

HTH,
Bernie
Excel MVP
 
Back
Top