473,406 Members | 2,894 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

Question: Parameter value query?

I have a query which asks for a parameter value to execute it.
To see the results I have to:
a) click on the query -- the "Enter Parameter Value" window pops up.
b) enter the parameter value
c) look at results in datasheet view

If I want to run the query again, I must
d) click to close the datasheet view
e) click on the query
f) enter the parameter value
g) look at results in datasheet view

Question: Is there a way to cut the number of steps in d) e) f) g) ?

thanks,
tom g

Nov 12 '05 #1
3 3088
Refer to a text box on a form instead of using a parameter.

Typically you type something like this into the Criteria row in query
design:
[Forms]![MyForm]![MyTextbox]

--
Allen Browne - Microsoft MVP. Perth, Western Australia.
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"thomas goodwin" <to*********@unc.edu> wrote in message
news:40********@news.unc.edu...
I have a query which asks for a parameter value to execute it.
To see the results I have to:
a) click on the query -- the "Enter Parameter Value" window pops up.
b) enter the parameter value
c) look at results in datasheet view

If I want to run the query again, I must
d) click to close the datasheet view
e) click on the query
f) enter the parameter value
g) look at results in datasheet view

Question: Is there a way to cut the number of steps in d) e) f) g) ?

thanks,
tom g

Nov 12 '05 #2

thomas goodwin <to*********@unc.edu> wrote in message
news:40********@news.unc.edu...
I have a query which asks for a parameter value to execute it.
To see the results I have to:
a) click on the query -- the "Enter Parameter Value" window pops up.
b) enter the parameter value
c) look at results in datasheet view

If I want to run the query again, I must
d) click to close the datasheet view
e) click on the query
f) enter the parameter value
g) look at results in datasheet view

Question: Is there a way to cut the number of steps in d) e) f) g) ?

thanks,
tom g


Much prefer doing this from a form.
Place a text box on a form (frmsearch). Call it say txtsearch.

in the query criteria put [Forms]![frmsearch]![txtsearch] - assuming you have
the names above.

by viewing query results in a form you have many more options as to how the data
is displayed.

So create a new form and use your query as it`s record source. the wizard will
do this for you.

On your search form add a command button to open your results form.
Depending on what you are seaching for using a combo box to select the criteria
works well.

You can also add 2 text boxes (formated to date) on your search form which
allows you to search between 2 dates

You would need something like this in the query date field criteria - Between
[Forms]![frmsearch]![firstdate] And [Forms]![frmsearch]![lastdate]

HTH
David B


Nov 12 '05 #3
"Allen Browne" <Al*********@SeeSig.Invalid> wrote in
news:40***********************@freenews.iinet.net. au:
Refer to a text box on a form instead of using a parameter.

Typically you type something like this into the Criteria row in
query design:
[Forms]![MyForm]![MyTextbox]


You can improve the performance of a query by defining the argument
as a parameter and typing it. I do this whenever I save a query that
is filtered on a form field.

--
David W. Fenton http://www.bway.net/~dfenton
dfenton at bway dot net http://www.bway.net/~dfassoc
Nov 12 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

14
by: deko | last post by:
For some reason this does not seem to be working... Am I missing something basic? Dim rst As DAO.Recordset Dim db As DAO.Database Set db = CurrentDb Set rst = db.OpenRecordset("qryEmailS") '...
3
by: thomas goodwin | last post by:
I have a query which asks for a parameter value to execute it. To see the results I have to: a) click on the query -- the "Enter Parameter Value" window pops up. b) enter the parameter value c)...
2
by: rg | last post by:
Hi all, I have query about passing a parameter from form to a query. My situation is as follows: I have a query that pulls up some data from a table, however there is a condition that must...
2
by: Robert Smith jr. | last post by:
Hello, Please pardon my newbie question ... I am building an ASP.NET page that displays a recordset with a Delete statement enabled (this all works fine). I want to Insert the current row...
5
by: ric_deez | last post by:
Hi there, I would like to create a simple search form to allow users to search for a job number based on a number of parameters. I think I understand how to use parameteres associated with Stored...
5
by: John | last post by:
Hi I have a parameterised query for a report like this; PARAMETERS Event_ID Short; SELECT DISTINCTROW Events., ... FROM Events WHERE (((Events.)=)); Now I am trying to run the report...
8
by: rbg | last post by:
I did use query plans to find out more. ( Please see the thread BELOW) I have a question on this, if someone can help me with that it will be great. In my SQL query that selects data from table,...
4
by: allanx38 | last post by:
I have a query that uses a value from a form as a criteria. For example looking for all customers belonging to a particular party. the criteria on the QBE looks like !! I am trying to open the...
5
n8kindt
by: n8kindt | last post by:
this is a very basic question but i might be making it more complicated than it should be. if i were to have a query with the following code SELECT Tbl1.ID, Tbl1., Tbl1. FROM Tbl1 WHERE...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.