Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / Interop / June 2005

Tip: Looking for answers? Try searching our database.

How to handle InvalidActiveXStateException

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Paul - 06 May 2005 12:53 GMT
Hi,

I'm attempting to create a vb.net class (no form) which uses
functionality provided by an activex control.

1) I've ran aximp and added the 2 references,

2) Added the declaration:
   Private WithEvents m_Asabtcp As AxASABTCPLib.AxAsabtcp

3) Initialized in the constructor:
   Public Sub New()
       m_Asabtcp = New AxASABTCPLib.AxAsabtcp

       Debug.WriteLine("AutoPoll enabled: " &
m_Asabtcp.AutoPollEnabled)
   End Sub

My problem (see msg below) occurs when trying to reference the property
in the property in the debug statement.  If I use the debugger, break,
set a watch & expand the properties in the watch window, everything
works.

"An unhandled exception of type 'InvalidActiveXStateException' occurred
in axasabtcplib.dll"

Thanks for your help!
rr_dot_net - 17 Jun 2005 21:10 GMT
This newsgroup is slightly abandoned....

I've found that activeX "controls" don't work real well without being
"sited" to a form or another control.  Usually the properties and methods are
not available at all prior to adding to a form.  I don't know the
intricacies, but that's been my experience....

> Hi,
>
[quoted text clipped - 23 lines]
>
> Thanks for your help!

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.