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  

Report Printing



 
 
Thread Tools Display Modes
  #1  
Old April 19th, 2010, 04:28 PM posted to microsoft.public.access.queries
Farkyss
external usenet poster
 
Posts: 25
Default Report Printing

I have a FORM. On this form is a BUTTON. This button should be opening an
REPORT and PRINTING it.

The REPORT is based on information pulled together in a QUERY. The query
asks for a Sales Number in a dialog box.

The FORM in question also has a Sales Number field. I need for the BUTTON to
open and print the REPORT based on the contents of the Sales Number field
rather than asking for it in a dialog box.

All attempts I have made to achieve this have failed. Any ideas?
  #2  
Old April 19th, 2010, 04:36 PM posted to microsoft.public.access.queries
Daryl S[_2_]
external usenet poster
 
Posts: 881
Default Report Printing

Farkyss -

In your query, instead of just having [Sales Number], you should have
something like Forms![YourFormName]![Sales Number]. The form must be open
for this to work.

In query design you can use the expression builder to get the syntax
correct. Use the forms column on the left to go to the form and then
double-click on the name of the control on that form that contains the Sales
Number.

--
Daryl S


"Farkyss" wrote:

I have a FORM. On this form is a BUTTON. This button should be opening an
REPORT and PRINTING it.

The REPORT is based on information pulled together in a QUERY. The query
asks for a Sales Number in a dialog box.

The FORM in question also has a Sales Number field. I need for the BUTTON to
open and print the REPORT based on the contents of the Sales Number field
rather than asking for it in a dialog box.

All attempts I have made to achieve this have failed. Any ideas?

  #3  
Old April 19th, 2010, 05:16 PM posted to microsoft.public.access.queries
Farkyss
external usenet poster
 
Posts: 25
Default Report Printing

Bang on. Thanks for that

"Daryl S" wrote:

Farkyss -

In your query, instead of just having [Sales Number], you should have
something like Forms![YourFormName]![Sales Number]. The form must be open
for this to work.

In query design you can use the expression builder to get the syntax
correct. Use the forms column on the left to go to the form and then
double-click on the name of the control on that form that contains the Sales
Number.

--
Daryl S


"Farkyss" wrote:

I have a FORM. On this form is a BUTTON. This button should be opening an
REPORT and PRINTING it.

The REPORT is based on information pulled together in a QUERY. The query
asks for a Sales Number in a dialog box.

The FORM in question also has a Sales Number field. I need for the BUTTON to
open and print the REPORT based on the contents of the Sales Number field
rather than asking for it in a dialog box.

All attempts I have made to achieve this have failed. 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 05:26 PM.


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