N
Norvin Laudon
Hi,
I have a legacy ActiveX control (circa 1996) which I would like to use in a
C# class, without using a form.
I am getting an exception thrown when I try to set properties on the
control: "An unhandled exception of type 'InvalidActiveXStateException'
occurred in axinterop.finsctllib.dll"
When I put an instance of the control on a form, and look at the
auto-generated code, I see a line (where "serial" is the name of the
control):
this.serial.OcxState =
((System.Windows.Forms.AxHost.State)(resources.GetObject("serial.OcxState"))
);
I think this is my problem. In my class, I need to initialize the "OCXState"
property of my control, but I don't have the "resources" variable which the
form has.
So my question: Is there any way to generate a default "OCXState" for the
control?
Thanks,
Norvin
I have a legacy ActiveX control (circa 1996) which I would like to use in a
C# class, without using a form.
I am getting an exception thrown when I try to set properties on the
control: "An unhandled exception of type 'InvalidActiveXStateException'
occurred in axinterop.finsctllib.dll"
When I put an instance of the control on a form, and look at the
auto-generated code, I see a line (where "serial" is the name of the
control):
this.serial.OcxState =
((System.Windows.Forms.AxHost.State)(resources.GetObject("serial.OcxState"))
);
I think this is my problem. In my class, I need to initialize the "OCXState"
property of my control, but I don't have the "resources" variable which the
form has.
So my question: Is there any way to generate a default "OCXState" for the
control?
Thanks,
Norvin