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

    Home » Forums » AskWoody support » Productivity software by function » MS Access and database help » Change Page Setup, Page tab = Landscape? (a2k (9.0.6926) SP-3 Jet 4.0 SP-8)

    Author
    Topic
    #454247

    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

    Viewing 1 reply thread
    Author
    Replies
    • #1127096

      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.

      • #1173754

        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

        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.

        • #1173758

          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).

          • #1173787

            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

            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).

    • #1173759

      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.

      • #1173766

        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,

        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

        • #1173773

          Does Hans’ suggestion regarding Named AutoCorrect help?

          • #1173788

            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

            Does Hans’ suggestion regarding Named AutoCorrect help?

    Viewing 1 reply thread
    Reply To: Change Page Setup, Page tab = Landscape? (a2k (9.0.6926) SP-3 Jet 4.0 SP-8)

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: