C
CornDog
It errors on rpt = Me!Comb0
My guess is it is becuase Me!Combo0 isnt of Report obj
type so... Im too tired at the moment to think on.
Dim rpt As Report
rpt = Me!Combo0
Reports!rpt.Filter = strSQL
My guess is it is becuase Me!Combo0 isnt of Report obj
type so... Im too tired at the moment to think on.
Dim rpt As Report
rpt = Me!Combo0
Reports!rpt.Filter = strSQL
-----Original Message-----
Try this:
Dim rpt As Report
rpt = Me!Combo0
Reports!rpt.Filter = strSQL
***Note: that the value in the bound column of your
combobox/listbox must be a string, and more specifically,
the exact name of the report.
.-----Original Message-----
Reports![rptOutstandingTransfers].Filter = strSQL
I need to be able to replace [rptOutstandingTransfers] with
something dynamic.
Preferably with a value from a control on a form.
I tried but failed
ALSO
I thought maybe I could construct a string like this
strTemp = "Reports![" & Me!Combo0.Value & "].ControlSource"
And the say something like strVariable = DoCmd.???? strTemp
strVariable woudl then = the controlsource of the report.
Any ideas is this possible what should I be doing?
Thanks for any help.
.