View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 27,285
Default Working with VBA classes via WSH possible?

Nothing to do with code would be accessible from a closed workbook.

Classes can only be used in the workbook in which they are defined to the
best of my knowledge, so if you wanted to make some type of library, then
you would probably do as you suggest, make them into a DLL or something in
VB6. That assumes that they just use generic VB6 objects, properties and
methods and nothing from Excel. An exported file is a simple text file.

--
Regards,
Tom Ogilvy

"Stefan Bialucha" wrote in message
...
I have created a few VBA objects ("classes") in a workbook. Now i would

like
to use them in a WSH script without opening the workbook as well as

calling
a workbook macro. Is it possible?

Could not find any information on that on the web so far. I've tried to
create the object via GetObject on exported .cls-file, but this does not
work. Do i maybe have to recompile it in VB6 instead or the like?

Thanks in advance,
Stefan Bialucha.