Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

add text box info to report

Status
Not open for further replies.

detdu

Technical User
May 23, 2003
36
SE
hello everyone

here is my question... i want a text box where i can write whatever i want.. then i want to print this information to a report.. how can i do that?

thx
 
I do that now... Here is the approach that I use.

I created a form that has a text box and a button. The text box is a dynamic Footer for the Report Form. The button simply does a Preview of the Report. I also have a check box if the user wants to have the footer displayed or not.

Once the Report Form is open is design Mode, make sure the form is also open. Then simply add the following to a text box on the Report form.

=IIf([Forms]![frm_Commission_Report]![chk_Display]=1,[Forms]![frm_Commission_Report]![REPORT_TEXT],"")

htwh,

Steve Medvid
"IT Consultant & Web Master"
e-Mail: Stephen_Medvid@GMACM.com

Chester County, PA Residents
Please Show Your Support...
 
hmm.. am i supposed to put

=IIf([Forms]![frm_Commission_Report]![chk_Display]=1,[Forms]![frm_Commission_Report]![REPORT_TEXT],"")

in the report or form?
 
i tried but it doesnt work on me... :/
 
Ok, Once you have a Form, you need to reference the form name, field.

In my example:
=IIf([Forms]![frm_Commission_Report]![chk_Display]=1,[Forms]![frm_Commission_Report]![REPORT_TEXT],"")

chk_Display is a Checkbox on my form
REPORT_TEXT is a Text Box on the form.
frm_Commission_Report is my form name.

If you choose not to use a Check box and simply display the contents of the Text Box in all cases, you can use the following on the Report Form within a Text box:

= [Forms]![YOUR FORM NAME]![FIELD NAME ON FORM]

Again, the Form that is used to Launch the Report must be open.

htwh,





Steve Medvid
"IT Consultant & Web Master"
e-Mail: Stephen_Medvid@GMACM.com

Chester County, PA Residents
Please Show Your Support...
 
Works fine for me..

Create a Form in Design View.
Create a field Text Box Called Test1.
Save the form as Form1.
Create a Report Form.
Within Detail Body Create a field Text Box Called Test2.
For the Test2 Field change Control Source to
"=[Forms]![Form1]![TEST1].[Value]"

Run Form1. Enter Value for Test1
Run Report - Should see value from Form1.

htwh


Steve Medvid
"IT Consultant & Web Master"
e-Mail: Stephen_Medvid@GMACM.com

Chester County, PA Residents
Please Show Your Support...
 
thanks alot.. i will try that.. :)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top