Open Reoprt with VBA?

  • Thread starter Thread starter Martijn van Oosterhout
  • Start date Start date
M

Martijn van Oosterhout

Hi I'm new here and have a simple question, if anyone can help me?

I am making a simple menu in Access and want to open a Report with this
code:

DoCmd.OpenReport "NameReport"

But now it prints the report instead of open the report. Does anyone
know the correct syntax to do this.

Sorry but I am a complete nOOb at this.

TIA

Martijn
 
Martijn,

Try:

DoCmd.OpenReport "NameReport", acViewPreview

HTH,
Nikos
 
Martijn,

Try:

DoCmd.OpenReport "NameReport", acViewPreview

HTH,
Nikos

Thanks Nikos,

That what I was looking for.

Regards, Martijn
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top