J
Juan Carlos
Hi
I have an ocx developed in VB 6.0 and I nedd to use it in
Window Form application in C#. When I do it, I get a
System.NullReferenceException
I've added the reference and in my application I wrote:
//Global Variables
Monitorsdn.MonitorSendClass sendMon = null;
short local = 0, remoto = 0;
string socket = "C", sPath = "C:\mon.ini"
public myForm() {
InitializeComponent();
InitializeOcx();
}
private void InicializeOcx() {
short shEvent = 1;
sendMon.Monitor(ref shEvent, ref local, ref remoto, ref
socket, ref sPath);
}
Do I need do or include something else??
What's wrong???
J.C.
I have an ocx developed in VB 6.0 and I nedd to use it in
Window Form application in C#. When I do it, I get a
System.NullReferenceException
I've added the reference and in my application I wrote:
//Global Variables
Monitorsdn.MonitorSendClass sendMon = null;
short local = 0, remoto = 0;
string socket = "C", sPath = "C:\mon.ini"
public myForm() {
InitializeComponent();
InitializeOcx();
}
private void InicializeOcx() {
short shEvent = 1;
sendMon.Monitor(ref shEvent, ref local, ref remoto, ref
socket, ref sPath);
}
Do I need do or include something else??
What's wrong???
J.C.