M
mbd-team
Hello,
i'm trying to use Access vom VB-6 as Automation Server. I want to use an
Access Form 'withevents'. Code is like:
dim withevents aForm as Access.Form
Sub test()
dim myAccess as new Access.Application
myAccess.OpenCurrentDatabase "test.mdb"
myAccess.DoCmd.OpenForm "MyForm"
set aForm=myAccess.Forms("MyForm")
....
Each Time the code is reaching the line set aForm=... I get an Automation
Error -2147220990. What is wrong with my code? I need to recognize the moment
the user is closing the form!
i'm trying to use Access vom VB-6 as Automation Server. I want to use an
Access Form 'withevents'. Code is like:
dim withevents aForm as Access.Form
Sub test()
dim myAccess as new Access.Application
myAccess.OpenCurrentDatabase "test.mdb"
myAccess.DoCmd.OpenForm "MyForm"
set aForm=myAccess.Forms("MyForm")
....
Each Time the code is reaching the line set aForm=... I get an Automation
Error -2147220990. What is wrong with my code? I need to recognize the moment
the user is closing the form!