How to use Windowless ActiveX.dll in my Project

Hello,

I am trying to use a ActiveX component (written by someone else) in my Visual Basic 2005 project. I am new to VB2005, so please bear with me.

I added the COM reference to the ActiveX.dll class to the project.
I choose the Toolbox Items from COM Components Tab and added the ActiveX component to the General Toolbox.

I am able to place this ActiveX component in the Main.vb form, I can see the object's properties but I encounter a problem when I attempt to run (F5) the project. I get the following error:

at System.Windows.Forms.UnsafeNativeMethods.IOleObject.DoVerb(Int32 iVerb, IntPtr lpmsg, IOleClientSite pActiveSite, Int32 lindex, IntPtr hwndParent, COMRECT lprcPosRect)
at System.Windows.Forms.AxHost.DoVerb(Int32 verb)
at System.Windows.Forms.AxHost.InPlaceActivate()
Unable to get window handle.. Windowless ActiveX are not supported.

What am I doing wrong? Your help is greatly appreciated.

Thank you.
[996 byte] By [cyman73] at [2007-11-20 0:36:33]
# 1 Re: How to use Windowless ActiveX.dll in my Project
Hello cyman! :wave:

I got these links for you, based on your error message.

http://www.kbalertz.com/834615/receive.error.message.delete.UserControl1.control.Windows.Service.project.Visual.Basic.application.aspx

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dndotnet/html/actxctrlswinforms.asp

I hope it helps a bit!
HanneSThEGreaT at 2007-11-10 3:12:43 >