Reports from Forms

ahamilton

New member
Local time
Today, 16:14
Joined
Oct 20, 2009
Messages
3
Hi guys,

I have a form that I run a report from a text box which the user can select a report type they want eg: East Link, West Link etc..., This can also be left blank & it runs the report with just entries from the one they have chosen, If they leave blank report has all entries which is what i want.

On the report the it shows what they chose in the header, except if they leave it blank, I need it to show something like "All Reports"

Hope I have explained easier enough

Thanks Drew
 
In my opinion the best way to do this is to design a new table:
tblReports
ID_Report (AutoNumber)
RepData (Text) - A short name that can fit in a control
RepTitle (Text) - What you wish to see as Report Title

The first record should be something like this
1 , All , All Reports
The next like this:
2 , East Link , Report for eastern area
3 , West Link , Report for western area

Then change that textbox with a combobox that lookup on first 2 fields on this table.
Set number of columns to 2 and the with of first one to 0 (zero).
Set the appropriate bound column (0 for first column or 1 for the second one)
Use the value from the bound column in order to filter your report.
Use the same value in a DLookup function that place the right value in your report name.
 

Users who are viewing this thread

Back
Top Bottom