Welcome to SPN

Register and Join the most happening forum of Sikh community & intellectuals from around the world.

Sign Up Now!

2 Copies Printed

Discussion in 'Information Technology' started by LJG, Jul 28, 2006.

Tags:
  1. LJG

    LJG
    Expand Collapse
    Guest

    I have the following code that merges data from a form into a word document,
    but for some reason it keeps printing 2 copies instead of just the one.This
    is my code:

    objword.ActiveDocument.PrintOut Background:=True
    objword.ActiveDocument.PrintOut , , , , , , , 1
    objword.ActiveDocument.Close SaveChanges:=wdDoNotSaveChanges

    All seems ok, I have tried to set the value to 0 but I get a message
    telling me I need to chose a number

    Any tips welcome
     
  2. Loading...


  3. BruceM

    BruceM
    Expand Collapse
    Guest

    You should post your question in a Word newsgroup, I think. This newsgroup
    is for Microsoft Access, a relational database program.

    "LJG" <lj_girvan@no_spam_hotmail.com> wrote in message
    news:Oq8Cr0aqGHA.2440@TK2MSFTNGP03.phx.gbl...
    >I have the following code that merges data from a form into a word
    >document, but for some reason it keeps printing 2 copies instead of just
    >the one.This is my code:
    >
    > objword.ActiveDocument.PrintOut Background:=True
    > objword.ActiveDocument.PrintOut , , , , , , , 1
    > objword.ActiveDocument.Close SaveChanges:=wdDoNotSaveChanges
    >
    > All seems ok, I have tried to set the value to 0 but I get a message
    > telling me I need to chose a number
    >
    > Any tips welcome
    >
    >
     
  4. LJG

    LJG
    Expand Collapse
    Guest

    This is an access problem, that code is behind a button the merges the data
    from access to word. The problem being it prints 2 copies rather than just 1


    "BruceM" <bamoob@yawwhodawtcalm.not> wrote in message
    news:%235Tf46aqGHA.3816@TK2MSFTNGP05.phx.gbl...
    > You should post your question in a Word newsgroup, I think. This
    > newsgroup is for Microsoft Access, a relational database program.
    >
    > "LJG" <lj_girvan@no_spam_hotmail.com> wrote in message
    > news:Oq8Cr0aqGHA.2440@TK2MSFTNGP03.phx.gbl...
    >>I have the following code that merges data from a form into a word
    >>document, but for some reason it keeps printing 2 copies instead of just
    >>the one.This is my code:
    >>
    >> objword.ActiveDocument.PrintOut Background:=True
    >> objword.ActiveDocument.PrintOut , , , , , , , 1
    >> objword.ActiveDocument.Close SaveChanges:=wdDoNotSaveChanges
    >>
    >> All seems ok, I have tried to set the value to 0 but I get a message
    >> telling me I need to chose a number
    >>
    >> Any tips welcome
    >>
    >>

    >
    >
     
  5. Douglas J. Steele

    Douglas J. Steele
    Expand Collapse
    Guest

    While you may be using Access to drive the printing, it's still a Word
    method. There may be problems using PrintOut in Word that we're not aware
    of, but that someone in the Word newsgroup can identify.

    That having been said, seems to me that you're calling the PrintOut method
    twice, so that it's only natural that you'd get two copies. What happens if
    you remove the second call to PrintOut, or try:

    objword.ActiveDocument.PrintOut Background:=True, Copies:=1
    objword.ActiveDocument.Close SaveChanges:=wdDoNotSaveChanges


    --
    Doug Steele, Microsoft Access MVP
    http://I.Am/DougSteele
    (no e-mails, please!)


    "LJG" <lj_girvan@no_spam_hotmail.com> wrote in message
    news:%23OikvIbqGHA.3732@TK2MSFTNGP04.phx.gbl...
    >
    >
    > This is an access problem, that code is behind a button the merges the

    data
    > from access to word. The problem being it prints 2 copies rather than just

    1
    >
    >
    > "BruceM" <bamoob@yawwhodawtcalm.not> wrote in message
    > news:%235Tf46aqGHA.3816@TK2MSFTNGP05.phx.gbl...
    > > You should post your question in a Word newsgroup, I think. This
    > > newsgroup is for Microsoft Access, a relational database program.
    > >
    > > "LJG" <lj_girvan@no_spam_hotmail.com> wrote in message
    > > news:Oq8Cr0aqGHA.2440@TK2MSFTNGP03.phx.gbl...
    > >>I have the following code that merges data from a form into a word
    > >>document, but for some reason it keeps printing 2 copies instead of just
    > >>the one.This is my code:
    > >>
    > >> objword.ActiveDocument.PrintOut Background:=True
    > >> objword.ActiveDocument.PrintOut , , , , , , , 1
    > >> objword.ActiveDocument.Close SaveChanges:=wdDoNotSaveChanges
    > >>
    > >> All seems ok, I have tried to set the value to 0 but I get a message
    > >> telling me I need to chose a number
    > >>
    > >> Any tips welcome
    > >>
    > >>

    > >
    > >

    >
    >
     
  6. wynne lindbergh

    wynne lindbergh
    Expand Collapse
    Guest

    in article Oq8Cr0aqGHA.2440@TK2MSFTNGP03.phx.gbl, LJG at
    lj_girvan@no_spam_hotmail.com wrote on 7/17/06 7:27 AM:

    > I have the following code that merges data from a form into a word document,
    > but for some reason it keeps printing 2 copies instead of just the one.This
    > is my code:
    >
    > objword.ActiveDocument.PrintOut Background:=True
    > objword.ActiveDocument.PrintOut , , , , , , , 1
    > objword.ActiveDocument.Close SaveChanges:=wdDoNotSaveChanges
    >
    > All seems ok, I have tried to set the value to 0 but I get a message
    > telling me I need to chose a number
    >
    > Any tips welcome
    >
    >

    I just want to know if I can send email on this application...! (Have a Mac
    0S 9)
     

Share This Page