|
-
Mar 2nd, 2004, 05:40 PM
#1
Thread Starter
Junior Member
re-usable code
if i have a Class Module within an executable file, can i call a method from that Class from another executable file.
Thanks
Sam
-
Mar 2nd, 2004, 05:44 PM
#2
No, you would have to create a DLL with the class file.
Laugh, and the world laughs with you. Cry, and you just water down your vodka.
Take credit, not responsibility
-
Mar 2nd, 2004, 05:46 PM
#3
You can instantiate the class in the second program, and use it, but how would you expect to use it across programs? An instance of the class would be much like a global variable of any other type. Would you realistically expect to be able to use that variable in a second program?
Uh, in other words, no. If the second program is running, you could get the two to communicate such that you could use it, but calling a function in a separate execution space seems like a strange thing to allow. The address of the function would be different each time the other program ran.
-
Mar 2nd, 2004, 05:47 PM
#4
Thread Starter
Junior Member
-
Mar 2nd, 2004, 06:05 PM
#5
Ummm...... if it is a standard EXE, no. But if you create it as an ActiveX EXE, then yes you can, as long as the class is public as well.
TG
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
|