suchasynic
Technical User
- Feb 11, 2003
- 91
Hi,
I'm having issues with DoCmd.GotoControl
I have a form called Contacts
This form has a tab control on it with 4 tabs (pgeGeneral, pgeShippingAddress,pgeAffilliations,pgeCallNotes)
On pgeCallNotes, I have a subform. The control source is a query to table called "call" -- contactID = Forms!Contacts!ContactID. The Subform (Call Notes Subform) has several controls -- call date, call time, call notes,....
On the pgeCallNotes Tab Control, I also have a cmd button to add a record to the call table (btnAddCallNote)
When I click on my pgeCallNotes tab control the control call date on the Call Notes Subform is always the focus.
I added the follwing code to the pgeCallNotes Click event:
DoCmd.GotoControl "btnAddCallNote"
This doesn't seem to work -- if I add this code to the Call Notes Subform Load Event -- then when opening the main form I go to the pgeCallNotes tab right away & I don't want that.
I've tried many things -- I did have it working at one point, but then I had issues when I would click on a different tab control on the main form and go back to the pgeCallNotes tab control -- the selected control is not btnAddCallNote like I want.
I'm spinning my wheels -- any help is much appreciated
I'm having issues with DoCmd.GotoControl
I have a form called Contacts
This form has a tab control on it with 4 tabs (pgeGeneral, pgeShippingAddress,pgeAffilliations,pgeCallNotes)
On pgeCallNotes, I have a subform. The control source is a query to table called "call" -- contactID = Forms!Contacts!ContactID. The Subform (Call Notes Subform) has several controls -- call date, call time, call notes,....
On the pgeCallNotes Tab Control, I also have a cmd button to add a record to the call table (btnAddCallNote)
When I click on my pgeCallNotes tab control the control call date on the Call Notes Subform is always the focus.
I added the follwing code to the pgeCallNotes Click event:
DoCmd.GotoControl "btnAddCallNote"
This doesn't seem to work -- if I add this code to the Call Notes Subform Load Event -- then when opening the main form I go to the pgeCallNotes tab right away & I don't want that.
I've tried many things -- I did have it working at one point, but then I had issues when I would click on a different tab control on the main form and go back to the pgeCallNotes tab control -- the selected control is not btnAddCallNote like I want.
I'm spinning my wheels -- any help is much appreciated