?
Solved

Access VBA Preview / Printing Report

Posted on 2008-10-14
5
Medium Priority
?
1,823 Views
Last Modified: 2010-04-21
I have a report which i want to create 2 buttons 1 to preview the report and the other to print the report in 1 click ie print to deafult printer and based on page ranges saved in table.

i have the below code to preview but don't know how to get that to print.  In 2007 how do you convert a macro to vba code

DoCmd.OpenReport "rpt_printorders", acViewPreview

dave
0
Comment
Question by:david_88
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 8

Expert Comment

by:Jupiler78
ID: 22709593
Hello david_88,

DoCmd.printout

What do you mean by the convert macro?

Regards,

Jupiler78
0
 

Author Comment

by:david_88
ID: 22709626
sometimes its easier to create a macro and then convert to vba which you could do in 2003
0
 
LVL 8

Accepted Solution

by:
Jupiler78 earned 2000 total points
ID: 22709634
Oh ok, I never work that way.
So on that part I can't offer any help I think.
How did you do that on 2003 then?

Did the DoCmd.printout work?
0
 

Author Closing Comment

by:david_88
ID: 31505802
yeah thanks
0
 
LVL 8

Expert Comment

by:Jupiler78
ID: 22709756
Glad I could help.
Good luck and thanks for the points & grade.

Jupiler78
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

It’s been over a month into 2017, and there is already a sophisticated Gmail phishing email making it rounds. New techniques and tactics, have given hackers a way to authentically impersonate your contacts.How it Works The attack works by targeti…
AutoNumbers should increment automatically, without duplicates.  But sometimes something goes wrong, and the next AutoNumber value is a duplicate.  This article shows how to recover from this problem.
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…
Suggested Courses

764 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question