A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Using Forms
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Tab control not working with queries



 
 
Thread Tools Display Modes
  #1  
Old December 31st, 2009, 02:21 PM posted to microsoft.public.access.forms
szag via AccessMonster.com
external usenet poster
 
Posts: 99
Default Tab control not working with queries

I have a form with a tab control on it. Within one of the tabs I have a
subform. the problem I have is that I have a button on this subform that runs
a report based on a selection within this subform. Bottom line is it appears
that the query (that the report uses) doesn't recognize the criteria - [Forms]
![F_AFE_subform]![AFE_ID] - because it is not part of the main form that the
tab control is on. Is there a way to accomplish this?

--
Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/For...forms/200912/1

  #2  
Old December 31st, 2009, 02:44 PM posted to microsoft.public.access.forms
Bob Quintal
external usenet poster
 
Posts: 939
Default Tab control not working with queries

"szag via AccessMonster.com" u2885@uwe wrote in
news:a169ec0e09c4a@uwe:

I have a form with a tab control on it. Within one of the tabs I
have a subform. the problem I have is that I have a button on this
subform that runs a report based on a selection within this
subform. Bottom line is it appears that the query (that the report
uses) doesn't recognize the criteria - [Forms]
![F_AFE_subform]![AFE_ID] - because it is not part of the main
form that the tab control is on. Is there a way to accomplish
this?

yes. To refer to a control on a subform, you must define the full
hiearchy of forms![mainformname]![subformcontrol].form![textboxname]

Note that the subform control name is not necessarily the name of the
form embedded in the main form.

see http://www.mvps.org/access/forms/frm0031.htm



--
Bob Quintal

PA is y I've altered my email address.
  #3  
Old December 31st, 2009, 02:57 PM posted to microsoft.public.access.forms
szag via AccessMonster.com
external usenet poster
 
Posts: 99
Default Tab control not working with queries

Thanks Bob. I really appreciate all of the great help I have received on this
site over the years!

Bob Quintal wrote:
I have a form with a tab control on it. Within one of the tabs I
have a subform. the problem I have is that I have a button on this

[quoted text clipped - 4 lines]
form that the tab control is on. Is there a way to accomplish
this?


yes. To refer to a control on a subform, you must define the full
hiearchy of forms![mainformname]![subformcontrol].form![textboxname]

Note that the subform control name is not necessarily the name of the
form embedded in the main form.

see http://www.mvps.org/access/forms/frm0031.htm


--
Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/For...forms/200912/1

  #4  
Old December 31st, 2009, 03:08 PM posted to microsoft.public.access.forms
szag via AccessMonster.com
external usenet poster
 
Posts: 99
Default Tab control not working with queries

still have an issue -
The main form is: F_Master_Buyer
The form on the tab contol is: F_AFE
The subform in F_AFE is: F_AFE_subform
The textbox I am trying to use from the F_AFE_subform is: AFE_ID

How would this criteria look in the query?

szag wrote:
I have a form with a tab control on it. Within one of the tabs I have a
subform. the problem I have is that I have a button on this subform that runs
a report based on a selection within this subform. Bottom line is it appears
that the query (that the report uses) doesn't recognize the criteria - [Forms]
![F_AFE_subform]![AFE_ID] - because it is not part of the main form that the
tab control is on. Is there a way to accomplish this?


--
Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/For...forms/200912/1

  #5  
Old December 31st, 2009, 03:38 PM posted to microsoft.public.access.forms
szag via AccessMonster.com
external usenet poster
 
Posts: 99
Default Tab control not working with queries

forget it - I answered my own question. thanks again.

szag wrote:
still have an issue -
The main form is: F_Master_Buyer
The form on the tab contol is: F_AFE
The subform in F_AFE is: F_AFE_subform
The textbox I am trying to use from the F_AFE_subform is: AFE_ID

How would this criteria look in the query?

I have a form with a tab control on it. Within one of the tabs I have a
subform. the problem I have is that I have a button on this subform that runs
a report based on a selection within this subform. Bottom line is it appears
that the query (that the report uses) doesn't recognize the criteria - [Forms]
![F_AFE_subform]![AFE_ID] - because it is not part of the main form that the
tab control is on. Is there a way to accomplish this?


--
Message posted via http://www.accessmonster.com

  #6  
Old January 1st, 2010, 01:43 PM posted to microsoft.public.access.forms
Jeff Boyce
external usenet poster
 
Posts: 1,555
Default Tab control not working with queries

Consider posting your solution... someone else may be looking for an answer
to this or a similar question some day ...

--

Regards

Jeff Boyce
Microsoft Access MVP

Disclaimer: This author may have received products and services mentioned in
this post. Mention and/or description of a product or service herein does
not constitute endorsement thereof.

Any code or pseudocode included in this post is offered "as is", with no
guarantee as to suitability.

You can thank the FTC of the USA for making this disclaimer
possible/necessary.


"szag via AccessMonster.com" u2885@uwe wrote in message
news:a16a9727fbd9e@uwe...
forget it - I answered my own question. thanks again.

szag wrote:
still have an issue -
The main form is: F_Master_Buyer
The form on the tab contol is: F_AFE
The subform in F_AFE is: F_AFE_subform
The textbox I am trying to use from the F_AFE_subform is: AFE_ID

How would this criteria look in the query?

I have a form with a tab control on it. Within one of the tabs I have a
subform. the problem I have is that I have a button on this subform that
runs
a report based on a selection within this subform. Bottom line is it
appears
that the query (that the report uses) doesn't recognize the criteria -
[Forms]
![F_AFE_subform]![AFE_ID] - because it is not part of the main form that
the
tab control is on. Is there a way to accomplish this?


--
Message posted via http://www.accessmonster.com



  #7  
Old January 4th, 2010, 02:15 PM posted to microsoft.public.access.forms
szag via AccessMonster.com
external usenet poster
 
Posts: 99
Default Tab control not working with queries

In the query criteria:

[Forms]![F_Master_Buyer]![F_AFE].[Form]![F_AFE_subform].[Form]![AFE_ID]

Jeff Boyce wrote:
Consider posting your solution... someone else may be looking for an answer
to this or a similar question some day ...

forget it - I answered my own question. thanks again.

[quoted text clipped - 16 lines]
the
tab control is on. Is there a way to accomplish this?


--
Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/For...forms/201001/1

  #8  
Old January 4th, 2010, 02:41 PM posted to microsoft.public.access.forms
Dirk Goldgar
external usenet poster
 
Posts: 2,529
Default Tab control not working with queries

"szag via AccessMonster.com" u2885@uwe wrote in message
news:a19c298604fac@uwe...
In the query criteria:

[Forms]![F_Master_Buyer]![F_AFE].[Form]![F_AFE_subform].[Form]![AFE_ID]


For future reference, that first ".Form" qualifier is redundant. You can
write just:

[Forms]![F_Master_Buyer]![F_AFE]![F_AFE_subform].[Form]![AFE_ID]


--
Dirk Goldgar, MS Access MVP
Access tips: www.datagnostics.com/tips.html

(please reply to the newsgroup)

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 08:14 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.