Results 1 to 9 of 9
  1. #1
    Silver Lounger
    Join Date
    Jun 2001
    Location
    Niagara Falls, New York, USA
    Posts
    1,878
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Change Page Setup, Page tab = Landscape? (a2k (9.0.6926) SP-3 Jet 4.0 SP-8)

    Is there any way to set (acCmdPageSetup) Page Setup, Page tab = Landscape after opening the database?

    I want to open a query then Print Preview

    Currently the Page tab is set to Portrait by default I would like it set to Landscape by default after opening the database.

    Thanks, John

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Change Page Setup, Page tab = Landscape? (a2k (9.0.6926) SP-3 Jet 4.0

    In Access 2002 and later, you can specify Landscape orientation for the printer. You could create a function in a standard module:

    Public Function SetLandscape()
    Application.Printer.Orientation = acPRORLandscape
    End Sub

    and call this function from a macro named AutoExec. But the Printer object is not available in Access 2000. For forms and reports, you could use PrtDevMode, but that doesn't apply to queries.

    You shouldn't let the end user open queries anyway, they should only use forms and reports.

  3. #3
    4 Star Lounger
    Join Date
    Jan 2003
    Location
    Central Florida, USA
    Posts
    505
    Thanks
    5
    Thanked 0 Times in 0 Posts
    For some reason, when I move reports created in an Access 2003 Application from my machine to another, the reports designed for landscape print and preview in portrait. The user consistently has to preview the report, then File:Page Setup:Landscape before printing. The weird thing is that when they get to the File:Page Setup:Landscape it is already in Landscape, so the user clicks on OK, and it prints and previews fine. Is this something anyone has experienced before?

    Would I be able to run this module immediately before printing or previewing the report and force it to landscape at run time?

    I also have another app that results in similar problems. It also is created on my machine, and then moved to the same computer as above. If the user prints or previews without going to Page Setup menu, it prints the fonts at something like 72 point making the reports unprintable. However, if they go to the PageSetup for the report before printing all is well.

    One other point of significance is this occurs on four pc's at the same business. Office is not loaded on their company pc's individually, but instead they have an image that is used to make all pc's have the same programs and configurations initially. So if I can discover what causes this, I will need to get their IT gurus to change their image. However, since I don't have a reason that this occurs, it makes it difficult to communicate with their IT folks and discuss a solution.

    Any ideas are greatly appreciated.

    Thanks,

    Ken


    [quote name='HansV' post='735098' date='26-Sep-2008 04:29']In Access 2002 and later, you can specify Landscape orientation for the printer. You could create a function in a standard module:

    Public Function SetLandscape()
    Application.Printer.Orientation = acPRORLandscape
    End Sub

    and call this function from a macro named AutoExec. But the Printer object is not available in Access 2000. For forms and reports, you could use PrtDevMode, but that doesn't apply to queries.

    You shouldn't let the end user open queries anyway, they should only use forms and reports.[/quote]

  4. #4
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts
    Reputedly, having "Track Name AutoCorrect Info" turned on in the General tab of Tools | Options... may cause reports to lose their page setup, apart from slowing down performance in general. So I'd turn this feature off, then distribute the database again (the setting is stored with the database).

  5. #5
    Super Moderator
    Join Date
    Aug 2001
    Location
    Evergreen, CO, USA
    Posts
    6,624
    Thanks
    3
    Thanked 60 Times in 60 Posts
    The most common reason for this issue is that the Printer Names (including the port) are not the same as your PC. That is especially true if you are specifying a printer that the report must print to. A second issue that sometimes occurs is that you are using a paper size that isn't available on the default printer - in that case Access wants to default to Letter and Portrait, or so it seems.
    Wendell

  6. #6
    4 Star Lounger
    Join Date
    Jan 2003
    Location
    Central Florida, USA
    Posts
    505
    Thanks
    5
    Thanked 0 Times in 0 Posts
    [quote name='WendellB' post='789378' date='17-Aug-2009 14:22']The most common reason for this issue is that the Printer Names (including the port) are not the same as your PC. That is especially true if you are specifying a printer that the report must print to. A second issue that sometimes occurs is that you are using a paper size that isn't available on the default printer - in that case Access wants to default to Letter and Portrait, or so it seems.[/quote]

    Wendell,

    Thanks for the heads up. I don't believe this to be the issue, as the specific printer in this case is an Acrobat pdf, and both my machine and the users have Acrobat printers. This has been going on now for nearly three years and we have just lived with it. They now have a new user who is less patient, and in all honesty it is something I should have researched sooner.

    In all cases, the paper size is 8 1/2" x 11" (Letter).

    I also have code that changes their default printer to Acrobat pdf during the print process and then switches it back when done. That is a relatively new addition and the problem was occurring prior to that update.

    Thanks again for your help.

    Ken

  7. #7
    Super Moderator
    Join Date
    Aug 2001
    Location
    Evergreen, CO, USA
    Posts
    6,624
    Thanks
    3
    Thanked 60 Times in 60 Posts
    Does Hans' suggestion regarding Named AutoCorrect help?
    Wendell

  8. #8
    4 Star Lounger
    Join Date
    Jan 2003
    Location
    Central Florida, USA
    Posts
    505
    Thanks
    5
    Thanked 0 Times in 0 Posts
    Hans,

    Thanks for the suggestion. I have made the change on this end, but will have to wait until later in the week before I can put it on the user's pc. I'll keep you posted.

    THANKS again for all your help.

    Ken

    [quote name='HansV' post='789377' date='17-Aug-2009 14:22']Reputedly, having "Track Name AutoCorrect Info" turned on in the General tab of Tools | Options... may cause reports to lose their page setup, apart from slowing down performance in general. So I'd turn this feature off, then distribute the database again (the setting is stored with the database).[/quote]

  9. #9
    4 Star Lounger
    Join Date
    Jan 2003
    Location
    Central Florida, USA
    Posts
    505
    Thanks
    5
    Thanked 0 Times in 0 Posts
    In my haste (or haze) of trying out Apple's Safari to access Woody's I overlooked Hans' suggestion.

    Thanks for pointing it out to me.

    Ken

    [quote name='WendellB' post='789416' date='17-Aug-2009 16:08']Does Hans' suggestion regarding Named AutoCorrect help?[/quote]

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •