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 » Database Design
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Return wildcards in Query Criteria from Form



 
 
Thread Tools Display Modes
  #1  
Old March 23rd, 2005, 08:11 PM
The parawon
external usenet poster
 
Posts: n/a
Default Return wildcards in Query Criteria from Form

I'm using the expression in a Query to return the data that someone will
enter into a form's text box. The criteria is returned properly and the
reports run fine when the data entry person types the exact name. For
example, if the entry person typed "Mike" in the form, the make table query
would run and return all records with Mike. If the data entry person enters
"Mi*" to get anything that sounds like Mike or Michelle, nothing no records
are returned. In the expression builder, I am only referencing the text box,
not any of it's properties. I'm simply using:
Forms![ContactPerson]![NameTextBox] in the criteria field of the make-table
query.

Any help in the right direction is appreciated.
  #2  
Old March 23rd, 2005, 08:23 PM
Rick B
external usenet poster
 
Posts: n/a
Default

Don't let them enter the wildcard, just have them enter a partial name....

Like Forms![ContactPerson]![NameTextBox]& "*"




Or if you want to find the string in any position...


Like "*" & Forms![ContactPerson]![NameTextBox] & "*"



Rick B



"The parawon" wrote in message
news
I'm using the expression in a Query to return the data that someone will
enter into a form's text box. The criteria is returned properly and the
reports run fine when the data entry person types the exact name. For
example, if the entry person typed "Mike" in the form, the make table

query
would run and return all records with Mike. If the data entry person

enters
"Mi*" to get anything that sounds like Mike or Michelle, nothing no

records
are returned. In the expression builder, I am only referencing the text

box,
not any of it's properties. I'm simply using:
Forms![ContactPerson]![NameTextBox] in the criteria field of the

make-table
query.

Any help in the right direction is appreciated.



  #3  
Old March 23rd, 2005, 10:20 PM
John Vinson
external usenet poster
 
Posts: n/a
Default

On Wed, 23 Mar 2005 12:11:04 -0800, "The parawon"
wrote:

I'm using the expression in a Query to return the data that someone will
enter into a form's text box. The criteria is returned properly and the
reports run fine when the data entry person types the exact name. For
example, if the entry person typed "Mike" in the form, the make table query
would run and return all records with Mike.


Ummm...

A MakeTable query is almost certainly neither necessary nor desirable
here. Are you making the very common mistaken assumption that you must
have data copied into a Table in order to generate a Report? That's
not the case; you can base a Report on a simple Select query.


John W. Vinson[MVP]
 




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

Similar Threads
Thread Thread Starter Forum Replies Last Post
Using form as criteria for report query Stepney_Clint General Discussion 4 February 7th, 2007 04:28 PM
Date query parameters entered from form not working kraymond Running & Setting Up Queries 1 February 21st, 2005 05:41 PM
Dates in a listbox connected to a form... RusCat Using Forms 13 November 25th, 2004 02:31 AM
Still Hoping for help with a Query problem Don Sealer Using Forms 15 November 13th, 2004 06:24 AM
Form to Enter Report Criteria works, but Query won't run from Macr BARKAROO Using Forms 1 October 16th, 2004 08:13 PM


All times are GMT +1. The time now is 07:53 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.