|
-
Nov 22nd, 2002, 12:35 PM
#1
Thread Starter
Registered User
Create an instance of an object from a string
Hi there all!
I have a question:
Is it possible to create an instance of an object if you have the name of the object in a string value?
In VB6 you could use the CreateObject Method like this for example:
Set xlApp = CreateObject("Excel.Apllication")
or something similiar I think. I have seen that the CreateObject function is still there, but didnt get lucky trying it out. CreateObject("Form1") for example, did not do the job.
I have a way around this problem, but this would sure save me a couple of pages of code.
Thanks!
/Leyan
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|