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 » Running & Setting Up Queries
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Parameter queries with custom dialogs



 
 
Thread Tools Display Modes
  #1  
Old September 29th, 2004, 05:22 PM
Luther
external usenet poster
 
Posts: n/a
Default Parameter queries with custom dialogs

Hello,

I am trying to design this custom query; here is the
scenario:
1. I already have a report that would display all of the
database; works well.
2. There is also a menu button for that report
What I would like to do is this:
When the menu button is clicked, the following happens:
1. it should open a small form that would give me 2
options:
a. command button for all records
b. parameter that gives the user a place to type the value
(in this case 'STATE=??'

When all said and done, the user will see the report
depending on what they chose. I am trying to wrap my head
around this concept, and needs some assistance to figure
this out.

Thanks.
  #2  
Old September 29th, 2004, 08:04 PM
hcj
external usenet poster
 
Posts: n/a
Default

Hi Luther,
You can do this with your single existing report with a
filter prompt something like:

[STATE] =[State=? - or leave blank for all]

The parameter statement above would be in the "filter"
property of the report, with the "filter on" property set
to yes. When the button runs the report, the user can
either supply a STATE name or leave the prompt empty. If
the former, only the selected STATE will be reported; if
the latter, all STATEs will be reported.

Let me know if this will work for you, or if you need more
discussion. You can also do this through a query using
the same prompt in the STATE criteria, and then the query
feeds the report with the same result.


-----Original Message-----
Hello,

I am trying to design this custom query; here is the
scenario:
1. I already have a report that would display all of

the
database; works well.
2. There is also a menu button for that report
What I would like to do is this:
When the menu button is clicked, the following happens:
1. it should open a small form that would give me 2
options:
a. command button for all records
b. parameter that gives the user a place to type the

value
(in this case 'STATE=??'

When all said and done, the user will see the report
depending on what they chose. I am trying to wrap my head
around this concept, and needs some assistance to figure
this out.

Thanks.
.

  #3  
Old September 29th, 2004, 10:03 PM
Luther
external usenet poster
 
Posts: n/a
Default

Thank you for responding...Strange enough, the "filter"
solution you provided is working well, but...When left
blank, the parameter give a blank report (incorrect),
where when supplied with a state name, it reports that
state (correct).
Is there anything missing there, please?

-----Original Message-----
Hi Luther,
You can do this with your single existing report with

a
filter prompt something like:

[STATE] =[State=? - or leave blank for all]

The parameter statement above would be in the "filter"
property of the report, with the "filter on" property set
to yes. When the button runs the report, the user can
either supply a STATE name or leave the prompt empty. If
the former, only the selected STATE will be reported; if
the latter, all STATEs will be reported.

Let me know if this will work for you, or if you need

more
discussion. You can also do this through a query using
the same prompt in the STATE criteria, and then the query
feeds the report with the same result.


-----Original Message-----
Hello,

I am trying to design this custom query; here is the
scenario:
1. I already have a report that would display all of

the
database; works well.
2. There is also a menu button for that report
What I would like to do is this:
When the menu button is clicked, the following happens:
1. it should open a small form that would give me 2
options:
a. command button for all records
b. parameter that gives the user a place to type the

value
(in this case 'STATE=??'

When all said and done, the user will see the report
depending on what they chose. I am trying to wrap my

head
around this concept, and needs some assistance to figure
this out.

Thanks.
.

.

  #4  
Old September 30th, 2004, 02:32 PM
external usenet poster
 
Posts: n/a
Default

Hi Luther,
Try this instead:
[STATE] like [State=? - or leave blank for all]&"*"

I borrowed some code that was for a slightly different
outcome and forgot the * for the general case. Actually,
this version should work even if the user supplies only
the first few unique characters. Eg, if STATE is spelled
out in the data base, then 'penn' would report
Pennsylvania only. If you use 2 letter postal codes, then
you'd need both characters, of course.

Please let me know if this works for you.

-----Original Message-----
Thank you for responding...Strange enough, the "filter"
solution you provided is working well, but...When left
blank, the parameter give a blank report (incorrect),
where when supplied with a state name, it reports that
state (correct).
Is there anything missing there, please?

-----Original Message-----
Hi Luther,
You can do this with your single existing report with

a
filter prompt something like:

[STATE] =[State=? - or leave blank for all]

The parameter statement above would be in the "filter"
property of the report, with the "filter on" property

set
to yes. When the button runs the report, the user can
either supply a STATE name or leave the prompt empty.

If
the former, only the selected STATE will be reported; if
the latter, all STATEs will be reported.

Let me know if this will work for you, or if you need

more
discussion. You can also do this through a query using
the same prompt in the STATE criteria, and then the

query
feeds the report with the same result.


-----Original Message-----
Hello,

I am trying to design this custom query; here is the
scenario:
1. I already have a report that would display all of

the
database; works well.
2. There is also a menu button for that report
What I would like to do is this:
When the menu button is clicked, the following happens:
1. it should open a small form that would give me 2
options:
a. command button for all records
b. parameter that gives the user a place to type the

value
(in this case 'STATE=??'

When all said and done, the user will see the report
depending on what they chose. I am trying to wrap my

head
around this concept, and needs some assistance to

figure
this out.

Thanks.
.

.

.

  #5  
Old September 30th, 2004, 03:24 PM
Luther
external usenet poster
 
Posts: n/a
Default

Thank you sooooo much. Works like a charm. I kind of had
an idea about "like", but wasn't sure of the syntax. It's
good to know that there are experts like you to lean on
for support.

-----Original Message-----
Hi Luther,
Try this instead:
[STATE] like [State=? - or leave blank for all]&"*"

I borrowed some code that was for a slightly different
outcome and forgot the * for the general case. Actually,
this version should work even if the user supplies only
the first few unique characters. Eg, if STATE is spelled
out in the data base, then 'penn' would report
Pennsylvania only. If you use 2 letter postal codes,

then
you'd need both characters, of course.

Please let me know if this works for you.

-----Original Message-----
Thank you for responding...Strange enough, the "filter"
solution you provided is working well, but...When left
blank, the parameter give a blank report (incorrect),
where when supplied with a state name, it reports that
state (correct).
Is there anything missing there, please?

-----Original Message-----
Hi Luther,
You can do this with your single existing report

with
a
filter prompt something like:

[STATE] =[State=? - or leave blank for all]

The parameter statement above would be in

the "filter"
property of the report, with the "filter on" property

set
to yes. When the button runs the report, the user can
either supply a STATE name or leave the prompt empty.

If
the former, only the selected STATE will be reported;

if
the latter, all STATEs will be reported.

Let me know if this will work for you, or if you need

more
discussion. You can also do this through a query using
the same prompt in the STATE criteria, and then the

query
feeds the report with the same result.


-----Original Message-----
Hello,

I am trying to design this custom query; here is the
scenario:
1. I already have a report that would display all of
the
database; works well.
2. There is also a menu button for that report
What I would like to do is this:
When the menu button is clicked, the following happens:
1. it should open a small form that would give me 2
options:
a. command button for all records
b. parameter that gives the user a place to type the
value
(in this case 'STATE=??'

When all said and done, the user will see the report
depending on what they chose. I am trying to wrap my

head
around this concept, and needs some assistance to

figure
this out.

Thanks.
.

.

.

.

  #6  
Old September 30th, 2004, 04:17 PM
external usenet poster
 
Posts: n/a
Default

You're very welcome, and glad to hear it does the job.
Good luck.

-----Original Message-----
Thank you sooooo much. Works like a charm. I kind of had
an idea about "like", but wasn't sure of the syntax. It's
good to know that there are experts like you to lean on
for support.

-----Original Message-----
Hi Luther,
Try this instead:
[STATE] like [State=? - or leave blank for all]&"*"

I borrowed some code that was for a slightly different
outcome and forgot the * for the general case.

Actually,
this version should work even if the user supplies only
the first few unique characters. Eg, if STATE is

spelled
out in the data base, then 'penn' would report
Pennsylvania only. If you use 2 letter postal codes,

then
you'd need both characters, of course.

Please let me know if this works for you.

-----Original Message-----
Thank you for responding...Strange enough, the "filter"
solution you provided is working well, but...When left
blank, the parameter give a blank report (incorrect),
where when supplied with a state name, it reports that
state (correct).
Is there anything missing there, please?

-----Original Message-----
Hi Luther,
You can do this with your single existing report

with
a
filter prompt something like:

[STATE] =[State=? - or leave blank for all]

The parameter statement above would be in

the "filter"
property of the report, with the "filter on" property

set
to yes. When the button runs the report, the user can
either supply a STATE name or leave the prompt empty.

If
the former, only the selected STATE will be reported;

if
the latter, all STATEs will be reported.

Let me know if this will work for you, or if you need
more
discussion. You can also do this through a query

using
the same prompt in the STATE criteria, and then the

query
feeds the report with the same result.


-----Original Message-----
Hello,

I am trying to design this custom query; here is the
scenario:
1. I already have a report that would display all of
the
database; works well.
2. There is also a menu button for that report
What I would like to do is this:
When the menu button is clicked, the following

happens:
1. it should open a small form that would give me 2
options:
a. command button for all records
b. parameter that gives the user a place to type the
value
(in this case 'STATE=??'

When all said and done, the user will see the report
depending on what they chose. I am trying to wrap my
head
around this concept, and needs some assistance to

figure
this out.

Thanks.
.

.

.

.

.

 




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
Filling out one parameter, selecting multiple queries Paul van der Heijden Running & Setting Up Queries 2 September 9th, 2004 09:15 AM
Refresh All with parameter queries Patti General Discussion 0 August 10th, 2004 08:38 PM
Using Forms for Parameter Queries Jon Using Forms 0 August 6th, 2004 03:58 AM
parameter queries seeker53 Running & Setting Up Queries 5 July 7th, 2004 09:35 PM


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