changing report's base table

  • Thread starter Thread starter thriveni
  • Start date Start date
T

thriveni

Using ACCESS 2000, I have a report that was creating on a
particular table, using the report wizard. If I wanted
another report that has a different table name but the
same layout as the first report, how can I change the
table name in the report so that I could make a copy and
use the same layout. I have made may modifications in the
first layout that I do not want to repeat for the second
report.
 
Using ACCESS 2000, I have a report that was creating on a
particular table, using the report wizard. If I wanted
another report that has a different table name but the
same layout as the first report, how can I change the
table name in the report so that I could make a copy and
use the same layout. I have made may modifications in the
first layout that I do not want to repeat for the second
report.

Right-click on the Report name on the main database folder.
Select Copy from the short-cut menu.
Click on an empty area of the database folder.
Paste.
Give the new report a different name.
Open the new report in design view.
Show the report's property sheet.
Click on the Data tab.
The first item is Recordsource.
Delete the current recordsource, and select the new one from the drop-
down.
Save the changes.

You can also use just one report for both tables, by simply deleting
the recordsource and leaving it blank.
Then code the Report Open event to set it's recordsource there,
according to a user selected value on a form:
If forms!FormName!OptionGroupName = 1 Then
Me.RecordSource = "Table1"
Else
Me.RecordSource = "Table2"
End If
The form would have to be open when the report is run.
 
Back
Top