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 biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

OpenArgs Statement Not available OnOpen

Status
Not open for further replies.

flaniganmj

Technical User
Jun 25, 2002
81
US
Howdy All,

I am using a form for selection of data criteria and from that I am building and SQL statemtent in which I was planning on using in the OpenArgs arguement of DoCmd.OpenReport. In the report OnOpen I use Me.ControlSource = Me.OpenArgs. This should work, I am little rusty with Access, as I have not used it in awhile. The OpenArgs is comming accross as Null, and I am getting an 'Invalid use of Null' error. I am doing something very simple wrong. Any help is appreciated.

Thanks,

flan
 
Up until Access 2000 at least, reports don't have OpenArgs properties. At least, you can't specify one in a
Code:
DoCmd.OpenReport{/code] command.

As far as I'm aware, up to and including Access 2000 you can only specify OpenArgs for forms. This is a bit rubbish, so hopefully it'll be added in A2002. [pc2] [URL unfurl="true"]http://www22.brinkster.com/accessory/[/URL]
 
Up until Access 2000 at least, reports don't have OpenArgs properties. At least, you can't specify one in a
Code:
DoCmd.OpenReport
command.

As far as I'm aware, up to and including Access 2000 you can only specify OpenArgs for forms. This is a bit rubbish, so hopefully it'll be added in A2002. [pc2]
 
I use 'fixed' strings in the OpenAgs, i.e. "Sales Summary" and from there use it in the report caption and txt boxes; so it must not allow me to use a variable string, i.e. mySQL. On the other hand, I know I have used this procedure before and I am very confused. Any other tips on how to pull a report using multiple criteria from a form. Without referencing the object variable in the query or report.

flan
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top