By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
434,871 Members | 2,337 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 434,871 IT Pros & Developers. It's quick & easy.

Macro Reports

P: n/a
I have the following fields in a table.
-JobNo (primary key)
-Assessor (combo box containing only two names to choose from ie. John,
Bill)
I have created two seperate reports which have exactly the same content
except that they have a different electronic signatures respective of the
person chosen from the Assessor combo box.
ie. Rpt_John and Rpt_Bill
To produce these reports, I currently have two macro's (one for each of the
two assessors) in a form (frm_main) whereupon clicking a particular macro
button (ie button named BILL), popup dialogue box (running a query....
qry_rpt_assessor) asks for the JobNo. Upon entering the number, the report
is produced based on the info that the particular jobno contains respective
to the assessor.
My question is: How can I create a macro or code that when the user is in a
particular record (jobno) that a report will be produced based on info that
is already there ie jobno and the assessor foregoing the prompt. So with
one click of the macro button, the report will be produced without any input
from the user ie. the report being able to gather the information from the
current jobno that the user is in and the assessor's name that has populated
the Assessor field box.
thanks for any help.

Nov 13 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
On Mon, 9 May 2005 22:43:08 +1000, "Jo K." <g4****@hotmail.com> wrote:

Check out DoCmd.OpenReport in the help file. It has an argument called
WhereClause. Use it to enter something like:
"JobNo=" & Forms!MyForm!MyJobNoControl

-Tom.
I have the following fields in a table.
-JobNo (primary key)
-Assessor (combo box containing only two names to choose from ie. John,
Bill)
I have created two seperate reports which have exactly the same content
except that they have a different electronic signatures respective of the
person chosen from the Assessor combo box.
ie. Rpt_John and Rpt_Bill
To produce these reports, I currently have two macro's (one for each of the
two assessors) in a form (frm_main) whereupon clicking a particular macro
button (ie button named BILL), popup dialogue box (running a query....
qry_rpt_assessor) asks for the JobNo. Upon entering the number, the report
is produced based on the info that the particular jobno contains respective
to the assessor.
My question is: How can I create a macro or code that when the user is in a
particular record (jobno) that a report will be produced based on info that
is already there ie jobno and the assessor foregoing the prompt. So with
one click of the macro button, the report will be produced without any input
from the user ie. the report being able to gather the information from the
current jobno that the user is in and the assessor's name that has populated
the Assessor field box.
thanks for any help.


Nov 13 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.