I'm trying to use an ActiveX control that works fine in VB.NET but not in
C#. The VB projects places the ActiveX control on a form. The C# project
doesn't because the control is used in a non form class. Here some samples
of the code and the values I get in C#:
[VB.NET] //this code is in the windows forms code generation area
Public WithEvents clUploader1 As AxclInetSuiteX5 .AxclUploader
....
Friend WithEvents Button1 As System.Windows. Forms.Button
<System.Diagnos tics.DebuggerSt epThrough()> Private Sub
InitializeCompo nent()
Me.components = New System.Componen tModel.Containe r
Dim resources As System.Resource s.ResourceManag er = New
System.Resource s.ResourceManag er(GetType(Form 1))
Me.ToolTip1 = New System.Windows. Forms.ToolTip(M e.components)
Me.clUploader1 = New AxclInetSuiteX5 .AxclUploader
[C#]
public class Class1
{
private AxclInetSuiteX5 .AxclUploader clUploader1 = new
AxclInetSuiteX5 .AxclUploader() ;
The values on clUploader1 in the watches window all have entries such as:
In the watches window, properties for clUploader1 give these errors:
BatchSize <error: an exception of type:
{System.Windows .Forms.AxHost.I nvalidActiveXSt ateException} occurred> int
and
OnURLParsing <undefined value>
AxclInetSuiteX5 .IclUploaderEve nts_OnURLParsin gEventHandler
When I try to use clUploader1 in the C# project, I get an error that it is
not set to an object instance. What exactly do I need to do for this to
work?
Thanks,
Brett
C#. The VB projects places the ActiveX control on a form. The C# project
doesn't because the control is used in a non form class. Here some samples
of the code and the values I get in C#:
[VB.NET] //this code is in the windows forms code generation area
Public WithEvents clUploader1 As AxclInetSuiteX5 .AxclUploader
....
Friend WithEvents Button1 As System.Windows. Forms.Button
<System.Diagnos tics.DebuggerSt epThrough()> Private Sub
InitializeCompo nent()
Me.components = New System.Componen tModel.Containe r
Dim resources As System.Resource s.ResourceManag er = New
System.Resource s.ResourceManag er(GetType(Form 1))
Me.ToolTip1 = New System.Windows. Forms.ToolTip(M e.components)
Me.clUploader1 = New AxclInetSuiteX5 .AxclUploader
[C#]
public class Class1
{
private AxclInetSuiteX5 .AxclUploader clUploader1 = new
AxclInetSuiteX5 .AxclUploader() ;
The values on clUploader1 in the watches window all have entries such as:
In the watches window, properties for clUploader1 give these errors:
BatchSize <error: an exception of type:
{System.Windows .Forms.AxHost.I nvalidActiveXSt ateException} occurred> int
and
OnURLParsing <undefined value>
AxclInetSuiteX5 .IclUploaderEve nts_OnURLParsin gEventHandler
When I try to use clUploader1 in the C# project, I get an error that it is
not set to an object instance. What exactly do I need to do for this to
work?
Thanks,
Brett