Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to use a Control created in C# as a form in VB6 [closed]

I have a user control created in a C# solution and I have to use that control in an existing form in VB. I am new to vb. Please help me out in this.

Thanks in advance.

like image 467
satyanarayana Avatar asked Jan 19 '26 21:01

satyanarayana


1 Answers

I have set the control like this when loading the data:

   Set mctldemo = Controls.Add("Democtl.Control", "ctlDemo", Me)

But forgot to mention the ClassInterface as shown in this link

[ClassInterface(ClassInterfaceType.AutoDual)]
    [ProgId("Democtl.Control")] 

Thank you all for responding to my question and thank you Nadeem_MK for the link

like image 77
satyanarayana Avatar answered Jan 22 '26 11:01

satyanarayana



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!