Hi all, I have developed an OCX that contains 3 webbrowser controls, and 3 frames. I am dynamically adding the webbrowser controls to the frames at runtime using
Set WebBrowser2 = Controls.Add("Shell.Explorer.2", "WebBrowser2", Frame2)
However when I add my ocx to word document, I get an error when I close the document. The error isn't very informative:
AppName: winword.exe AppVer: 9.0.0.2717 ModName: msvbvm60.dll
ModVer: 6.0.98.2 Offset: 00048991
I reckon it's because I am not correctly disposing of some of the controls. The question is, when do I dispose of the Webbrowser and Frame control? In the usercontrol_terminate event?
Thanks
Set WebBrowser2 = Controls.Add("Shell.Explorer.2", "WebBrowser2", Frame2)
However when I add my ocx to word document, I get an error when I close the document. The error isn't very informative:
AppName: winword.exe AppVer: 9.0.0.2717 ModName: msvbvm60.dll
ModVer: 6.0.98.2 Offset: 00048991
I reckon it's because I am not correctly disposing of some of the controls. The question is, when do I dispose of the Webbrowser and Frame control? In the usercontrol_terminate event?
Thanks