Is it possible to retrieve the query name for a report?
I am trying to create a button in a report and when the button is click, it would provide the name of the query that is behind the report (i.e. the query that is record source for the report).
How do I go about in achieving this?
I tried the following in the code for the button but it doesn't work
Dim qry_name as string
qry_name = Report.RecordSource
Msgbox qyr_name
I am trying to create a button in a report and when the button is click, it would provide the name of the query that is behind the report (i.e. the query that is record source for the report).
How do I go about in achieving this?
I tried the following in the code for the button but it doesn't work
Dim qry_name as string
qry_name = Report.RecordSource
Msgbox qyr_name