If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#1
|
|||
|
|||
ActiveX headache
I had crafted an ActiveX control in VB6, embedded in an Microsoft
Office 2k3 database. It worked great. Now I'm getting a problem with the "onmousedown"... access is telling me that property is not available to embedded form activex controls. What hoops do I need to jump through to get the form to recognize the onmousedown event? If I import the form from a working MDB to a fresh MDB, the functionality is gone, even though the code is there. It's as though the event isn't triggering anymore. Dan |
#2
|
|||
|
|||
ActiveX headache
Hello Dan.
Dan " wrote: I had crafted an ActiveX control in VB6, embedded in an Microsoft Office 2k3 database. It worked great. Now I'm getting a problem with the "onmousedown"... access is telling me that property is not available to embedded form activex controls. How is Access "telling" you that? What hoops do I need to jump through to get the form to recognize the onmousedown event? If I import the form from a working MDB to a fresh MDB, the functionality is gone, even though the code is there. It's as though the event isn't triggering anymore. First: when importing the form to a new mdb, did you add a reference to the ActiveX control? Then: Does your ActiveX control fire a mousedown event at all? If so: Define a WithEvents variable at the forms level, store a reference to your ActiveX control in that variable in the Load event of the form. Set the variable to Nothing in the Unload event of the form. Create an event procedure for the mousedown event of "the variable" using the drop down boxes at the top of the code window. -- Regards, Wolfgang |
#3
|
|||
|
|||
ActiveX headache
wrote in message
... I had crafted an ActiveX control in VB6, embedded in an Microsoft Office 2k3 database. It worked great. Now I'm getting a problem with the "onmousedown"... access is telling me that property is not available to embedded form activex controls. What hoops do I need to jump through to get the form to recognize the onmousedown event? If I import the form from a working MDB to a fresh MDB, the functionality is gone, even though the code is there. It's as though the event isn't triggering anymore. Dan Perhaps your reference needs to be rebuilt. Or you may need to re-register your ActiveX control. To do that: Start Run then type: regsvr32.exe "C:\The full path to your control.ocx" and press enter. You should get a message back that the registration has succeeded. Then reset the reference. -- Arvin Meyer, MCP, MVP http://www.datastrat.com http://www.mvps.org/access http://www.accessmvp.com |
Thread Tools | |
Display Modes | |
|
|