Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Reference a control when inside a form on a tab control 1

Status
Not open for further replies.

Apollo13a

Technical User
Apr 27, 2003
277
US
Hello, I'm trying to create a parameter query and I need to reference a control(cboItemDesc) that is on a form(frmReports) that is on Page 2 of a tab control(tabctl0). The tabctl0 is on my main form(frmMain). I tried
Code:
 Forms!frmMain!frmReports.cboItemDesc.
But it didn't work. I thought I read somewhere that I don't have to reference the tab control but I tried that anyway and it didn't work either. My parameter query works fine if I reference the frmreports directly but I can't seem to nail down the syntax when it's on my main form.
 
Is you control on a subform? The tab control should not make any difference. You might want to try:
Forms!fmrMain!frmReports.Form!cboItemDesc

Duane MS Access MVP
[green]Ask a great question, get a great answer.[/green] [red]Ask a vague question, get a vague answer.[/red]
[green]Find out how to get great answers faq219-2884.[/green]
 
Thanks for the reply. My control is not on a subform but it is on a form I created separately and then dragged onto my main form. I just deleted the form and put the controls on the main form.
Thanks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top