Results 1 to 7 of 7
  1. #1
    Join Date
    Nov 2007
    Posts
    38

    Unanswered: Printing Records

    OK, sorry about this, probably a simple answer, but its bugging me!

    I use a form for data input, due to the way it is laid out, if i need to print a copy of it i have a print record button on the screen (simple so far!)

    I have set the page settings to print in landscape so all of the record prints out, but after a few days (or colleague goes in) then the setting reverts to portrait and prints over 2 pages.

    How can i force the page to only print in landscape?
    (If this was Excel i would know how to do it, but access doesnt like the coding!)

    TIA
    Last edited by wartroll; 04-16-08 at 06:15.

  2. #2
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    I never print forms so sorry I don't know the answer, but what I would recommend you do is make a report out of the form and print the report with the button instead of the form.

    Maybe if you could isolate exactly what action is resetting it, you might be put on the right track?

    Sorry, probably not a lot of help there.
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!


    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

  3. #3
    Join Date
    Nov 2004
    Location
    out on a limb
    Posts
    13,692
    Provided Answers: 59
    check the settings you are using inthe print macro... im pretty certain you can use a system constant to declare landscape.

    its the usual problem of printing from within Access.. each time you change printers or the default printer you cna have these probelms unless you expressly tell Access what to do.

    what code are you using to print the item?
    what code is behind wahtever button you are using?

  4. #4
    Join Date
    Nov 2007
    Posts
    38
    the code i currently have is as follows

    Private Sub print_this_record_Click()
    On Error GoTo Err_print_this_record_Click

    Dim stDocName As String

    stDocName = "print"
    DoCmd.RunMacro stDocName

    Exit_print_this_record_Click:
    Exit Sub

    Err_print_this_record_Click:
    MsgBox Err.Description
    Resume Exit_print_this_record_Click

    End Sub

    I have been having a nose around in the VBA help, but not really making a lot of sence to me!!

  5. #5
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    All that does is runs a macro called "print". What is in that macro?
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!


    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

  6. #6
    Join Date
    Nov 2007
    Posts
    38
    oops, your right there!

    it links to a macro in access (built using the macro builder)
    action = printout
    print range = selection
    page from =
    page to =
    print quality = high
    copies = 1
    collate copies = yes


    that is all it offers! (cant see anything in VBA that shows actual coding)

    many thanks

  7. #7
    Join Date
    Nov 2007
    Location
    Adelaide, South Australia
    Posts
    4,049
    Ok so there's not much there that you can control matters with. I'd be making a report and calling the report from the button.
    Owner and Manager of
    CypherBYTE, Microsoft Access Development Specialists.
    Microsoft Access MCP.
    And all around nice guy!


    "Heck it's something understood by accountants ... so it can't be 'that' difficult..." -- Healdem
    "...teach a man to code and he'll be frustrated for life! " -- georgev

Posting Permissions

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