Wrox Programmer Forums
|
Access Discussion of Microsoft Access database design and programming. See also the forums for Access ASP and Access VBA.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Access section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old February 20th, 2008, 11:24 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 126
Thanks: 5
Thanked 0 Times in 0 Posts
Default Report print set-up

Hello all!
I have a report that automatically prints for the user. The problem is that our group in Europe uses a different size of paper. Is there a way to customize the Docmd.OpenReport command to use A4 as the paper size for printers in Europe and Letter size for printers in the USA?
-Or-
Does the command have a fit to page setting I can use?
(I can use a DLook-up to determine if the user is in Europe if I need to.)

Thanks in advance for the help!

Regards,
Laura

FYI...My user id has changed. My old id was lbreitenbach

The only thing standing between you and your goal is doubt. Quit doubting yourself and you'll be able to accomplish anything!
__________________
Regards,
Laura

The only thing standing between you and your goal is doubt. Quit doubting yourself and you'll be able to accomplish anything!
 
Old February 20th, 2008, 12:02 PM
Friend of Wrox
 
Join Date: Mar 2004
Posts: 3,069
Thanks: 0
Thanked 10 Times in 10 Posts
Default

WOuld it be possible to create a version of the report for Europe, and then check for the user location, and then just change the report name like:

If (user is in usa) Then
   sDoc = "repForUSA"
Else
   sDoc = "rptForEurope"
End If

DoCmd.OpenReport sDoc...

Did that help?

mmcdonal

Look it up at: http://wrox.books24x7.com
 
Old February 22nd, 2008, 12:22 PM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 126
Thanks: 5
Thanked 0 Times in 0 Posts
Default

Mmcdonal,
That is a good idea...Thanks! Do you happen to know if there is a line of code that will check the system files to see what Country or time zone their PC is set up as? That way I can use that in the If statements instead of maintaining a table with the information. (This would help also if a user is traveling.)

Regards,
Laura

FYI...My user id has changed. My old id was lbreitenbach

The only thing standing between you and your goal is doubt. Quit doubting yourself and you'll be able to accomplish anything!
 
Old February 25th, 2008, 08:31 AM
Friend of Wrox
 
Join Date: Mar 2004
Posts: 3,069
Thanks: 0
Thanked 10 Times in 10 Posts
Default

Sorry for the delay. We were out Friday due to weather. You can do this to retrieve the time zone:

sComp = "."
Set objWMI = GetObject("winmgmts:\\" & sComp & "\root\CIMV2")
Set colItems = objWMI.ExecQuery("SELECT * FROM Win32_TimeZone", "WQL")
For Each objItem In colItems
      sZone = objItem.Caption
Next

Then check sZone. On my PC it returns:

(GMT-05:00) Eastern Time (US & Canada)

So that should help. I would check the GMT value, perhaps, or the US & Canada string. To see all the possible values, double click your clock in the Sys Tray. When the Date and Time Properties dialog box comes up, click the Time Zone tab, and use the pull down at the top to see all the possible lines returned by this routine. Then you could create a table, or just do a Select Case statement.

Did that help?

mmcdonal

Look it up at: http://wrox.books24x7.com
 
Old February 25th, 2008, 09:04 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 126
Thanks: 5
Thanked 0 Times in 0 Posts
Default

mmcdonal,
Thank you so much for this information! I'll give this a try this week and let you know if I have any issues.


Regards,
Laura

FYI...My user id has changed. My old id was lbreitenbach

The only thing standing between you and your goal is doubt. Quit doubting yourself and you'll be able to accomplish anything!





Similar Threads
Thread Thread Starter Forum Replies Last Post
how to print sub report NagarajuK Crystal Reports 0 December 3rd, 2007 10:05 AM
How to set the print properties of excel with vb6 wyq1234 Visual Basic 2005 Basics 0 July 5th, 2006 10:09 AM
Access NO PRINT in Report sbergeron Access 14 March 25th, 2006 01:35 AM
print report lazio Crystal Reports 0 November 1st, 2004 08:38 AM
How to set browser print page setup from .Net k_kosaraju General .NET 2 March 15th, 2004 03:55 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.