Hello
I am developing an Access 2000 application in which forms are altered dynamically based on options chosen by the user.
The CreateObject Function places checkboxes and other objects on a form, and this works fine.
The key line of code is:
Set ctlCheck = CreateControl(frm.Name, acCheckBox, , , "", posX, posY, chkWidth, chkHeight)
My problem is that I want to place the objects on pages of a tab control. I can do this in 'click and point' mode, but when I try it with VBA code, the objects are attached to the form, not the tab control page.
Any suggestions on how to tie the CreateControl command to a tab control page?
Things I have tried without success include:
a) using the page object name as the form name (the first parameter in the brackets) - it appears that the object must be a form.
b) using the page objects collection as the parent.
Thanks for your help
Dan
I am developing an Access 2000 application in which forms are altered dynamically based on options chosen by the user.
The CreateObject Function places checkboxes and other objects on a form, and this works fine.
The key line of code is:
Set ctlCheck = CreateControl(frm.Name, acCheckBox, , , "", posX, posY, chkWidth, chkHeight)
My problem is that I want to place the objects on pages of a tab control. I can do this in 'click and point' mode, but when I try it with VBA code, the objects are attached to the form, not the tab control page.
Any suggestions on how to tie the CreateControl command to a tab control page?
Things I have tried without success include:
a) using the page object name as the form name (the first parameter in the brackets) - it appears that the object must be a form.
b) using the page objects collection as the parent.
Thanks for your help
Dan