Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > Microsoft Office > Access and Access VBA > Access VBA
Password Reminder
Register
Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
Access VBA Discuss using VBA for Access programming.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Access VBA section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old September 23rd, 2007, 09:57 PM
Registered User
 
Join Date: Sep 2007
Location: Greensboro, NC, USA.
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default Print 2 Forms using 1 Button

Hello, I am new to Microsoft Access and I have a couple of instructional books on it. What I am trying to do is be able to print two separate forms using one button. What I had to do is create an interactive form, but the form had too many options, so I had to split it into two separate forms. The forms will need to be printed after completion, and I was just wondering if anyone has any way that I can just attach one print button to pg. 2 and have it print both the first and second page. Thanks for your help!

Matt

Reply With Quote
  #2 (permalink)  
Old September 24th, 2007, 08:22 AM
Friend of Wrox
Points: 9,611, Level: 42
Points: 9,611, Level: 42 Points: 9,611, Level: 42 Points: 9,611, Level: 42
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Mar 2004
Location: Washington, DC, USA.
Posts: 3,069
Thanks: 0
Thanked 10 Times in 10 Posts
Default

You are printing forms? Are they both open at the same time? When you say "pg 2," do you mean that you have a tabbed form? Or two seperate forms? Why not print a report based on the information on the two forms?

mmcdonal
Reply With Quote
  #3 (permalink)  
Old September 24th, 2007, 08:55 PM
Registered User
 
Join Date: Sep 2007
Location: Greensboro, NC, USA.
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

hmm.. I haven't thought about this. I guess that's kind of elementary. It is not a tabbed form, but two separate forms. I guess I should try the report route, that may be easiest.

Reply With Quote
  #4 (permalink)  
Old September 24th, 2007, 08:55 PM
Registered User
 
Join Date: Sep 2007
Location: Greensboro, NC, USA.
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Though about that, sorry, typo.

Reply With Quote
  #5 (permalink)  
Old September 26th, 2007, 07:36 AM
Friend of Wrox
Points: 9,611, Level: 42
Points: 9,611, Level: 42 Points: 9,611, Level: 42 Points: 9,611, Level: 42
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Mar 2004
Location: Washington, DC, USA.
Posts: 3,069
Thanks: 0
Thanked 10 Times in 10 Posts
Default

You can take some query or value from the form, and then package the report using the value. For example, create a query that has all customers plus all their outstanding orders, let's say. Then take their customer number from the form, and run the report WHERE [CustomerNo] = Me.CustomerNo. You can either pass the parameter to the report on the DoCmd.OpenReport where clause, or you can create a query that has this in the Criteria line for the field you are passing (CustomerNo in this case):

[Forms]![frmMyCustomerForm].[txtMyCustomerNoField]

Did any of that help?


mmcdonal
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to print from windows forms?? tycotrix C# 1 January 11th, 2007 09:45 AM
Print Forms on Saperate Pages itHighway HTML Code Clinic 1 November 21st, 2005 08:04 AM
'print' button crmpicco Classic ASP Basics 0 February 8th, 2005 10:25 AM
view/print report from 2 different forms chacquard Access VBA 3 January 5th, 2005 10:00 PM
print button alitoday Classic ASP Basics 1 June 5th, 2004 05:01 AM



All times are GMT -4. The time now is 09:06 AM.


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.