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  

Only display fields if field matches criteria



 
 
Thread Tools Display Modes
  #1  
Old February 23rd, 2010, 05:30 PM posted to microsoft.public.access.forms
gab1972
external usenet poster
 
Posts: 7
Default Only display fields if field matches criteria

I'm trying to build a query where the field only displays "Show" if
the field matches a string.

For example, I have about 20 fields and each of them has the check box
to 'Show'. I only want the field to show if the text "Traffic ↔
PreCon" is in the field. I tried doing if statements and I found that
if the first field doesn't match this criteria, then none of them show
up. "Traffic ↔ PreCon" could be in field 3 or 13. I just want to
filter through the fields and only show the ones that have that
string.

Any ideas?
  #2  
Old February 23rd, 2010, 06:17 PM posted to microsoft.public.access.forms
Jeff Boyce
external usenet poster
 
Posts: 8,621
Default Only display fields if field matches criteria

I'm not sure I'm visualizing your data yet...

Are you saying that the string you are looking for could be in one of
several different columns/fields? If so, then there's a good chance you
have a ... spreadsheet, not a relational database table!

More info, please...

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.

"gab1972" wrote in message
...
I'm trying to build a query where the field only displays "Show" if
the field matches a string.

For example, I have about 20 fields and each of them has the check box
to 'Show'. I only want the field to show if the text "Traffic ?
PreCon" is in the field. I tried doing if statements and I found that
if the first field doesn't match this criteria, then none of them show
up. "Traffic ? PreCon" could be in field 3 or 13. I just want to
filter through the fields and only show the ones that have that
string.

Any ideas?


 




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 04:10 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.