|
-
Dec 19th, 2007, 03:47 AM
#1
Thread Starter
Fanatic Member
[Resolved] Raise Event from c# to VB6
I need to be able to raise an c# event - and that event to be listened to in VB6. However I can't find a way to do this - any suggestions?
Rob
Last edited by THEROB; Dec 20th, 2007 at 03:40 AM.
My secretary hopes that I will pay her, her landlord hopes that she will produce some rent, the Electricity Board hopes that he will settle their bill, and so on. I find it a wonderfully optimistic way of life. [Dirk Gently]
-
Dec 19th, 2007, 07:37 PM
#2
Re: Raise Event from c# to VB6
What are you trying to do? Is this a .Net DLL being referenced in VB6 or a VB6 com component being referenced in the C# application? Or are they completely seperate and you want one to work with the other?
-
Dec 20th, 2007, 03:40 AM
#3
Thread Starter
Fanatic Member
Re: Raise Event from c# to VB6
Thanks for the reply. I am trying to fire an event from c# and this to be listened to by vb6 com.
I found out how to do it:
just place this before the class definition:
[ComSourceInterfaces(typeof(AttributesEventInterface))]
[ClassInterface(ClassInterfaceType.AutoDual)]
[Guid("4AF51BE7-6C50-4422-8F76-40DC35219780")]
My secretary hopes that I will pay her, her landlord hopes that she will produce some rent, the Electricity Board hopes that he will settle their bill, and so on. I find it a wonderfully optimistic way of life. [Dirk Gently]
-
Dec 20th, 2007, 07:23 AM
#4
Re: [Resolved] Raise Event from c# to VB6
Events are slower than directly calling a method. Why not just call your method in the com object?
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
|