Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. Problem with printdialog

Problem with printdialog

Scheduled Pinned Locked Moved C#
graphicshelp
4 Posts 2 Posters 1 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    D i x y
    wrote on last edited by
    #1

    Hello friends i am developing an application in which there is printing option... The printing option is working well but the problem is when the printdialog shows and by default the numbers of copies is 1 and if i increase the numbers of copies 2 or 3 then its only print one copy only why number of copies option is not working.... CODE int count = Application.OpenForms.Count; for (int i = 1; i < count; i++) { PrintDialog myPrintDialog = new PrintDialog(); memoryImage = new System.Drawing.Bitmap(panel1.Width, panel1.Height); panel1.DrawToBitmap(memoryImage, panel1.ClientRectangle); if (myPrintDialog.ShowDialog() == DialogResult.OK) { myPrintDialog.Document = printDocument1; printDocument1.PrintController = new StandardPrintController(); printDocument1.Print(); } printDocument1.Dispose(); }

    X 1 Reply Last reply
    0
    • D D i x y

      Hello friends i am developing an application in which there is printing option... The printing option is working well but the problem is when the printdialog shows and by default the numbers of copies is 1 and if i increase the numbers of copies 2 or 3 then its only print one copy only why number of copies option is not working.... CODE int count = Application.OpenForms.Count; for (int i = 1; i < count; i++) { PrintDialog myPrintDialog = new PrintDialog(); memoryImage = new System.Drawing.Bitmap(panel1.Width, panel1.Height); panel1.DrawToBitmap(memoryImage, panel1.ClientRectangle); if (myPrintDialog.ShowDialog() == DialogResult.OK) { myPrintDialog.Document = printDocument1; printDocument1.PrintController = new StandardPrintController(); printDocument1.Print(); } printDocument1.Dispose(); }

      X Offline
      X Offline
      Xmen Real
      wrote on last edited by
      #2

      this function will not work automatically, you have to do this dynamtically...

      TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L %^]*IRXD#@GKCQ`R\^SF_WcHbORY87??6?N8?BcRAV\Z^&SU~%CSWQ@#2 W_AD`EPABIKRDFVS)EVLQK)JKSQXUFYK[M`UKs*$GwU#(QDXBER@CBN% Rs0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-i?TV.C\y -------------------------------------------------------- 128 bit encrypted signature, crack if you can

      D 1 Reply Last reply
      0
      • X Xmen Real

        this function will not work automatically, you have to do this dynamtically...

        TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L %^]*IRXD#@GKCQ`R\^SF_WcHbORY87??6?N8?BcRAV\Z^&SU~%CSWQ@#2 W_AD`EPABIKRDFVS)EVLQK)JKSQXUFYK[M`UKs*$GwU#(QDXBER@CBN% Rs0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-i?TV.C\y -------------------------------------------------------- 128 bit encrypted signature, crack if you can

        D Offline
        D Offline
        D i x y
        wrote on last edited by
        #3

        so how can i do this dynamically...............

        X 1 Reply Last reply
        0
        • D D i x y

          so how can i do this dynamically...............

          X Offline
          X Offline
          Xmen Real
          wrote on last edited by
          #4

          put a int to count, call the PrintDocument_Print() event until you counter reach to 0. Do this work when your all pages finished, or if you do not want Collate, then call and decrease counter on every print but this time you will need to set again the actual value to counter hope it will help

          TVMU^P[[IGIOQHG^JSH`A#@`RFJ\c^JPL>;"[,*/|+&WLEZGc`AFXc!L %^]*IRXD#@GKCQ`R\^SF_WcHbORY87??6?N8?BcRAV\Z^&SU~%CSWQ@#2 W_AD`EPABIKRDFVS)EVLQK)JKSQXUFYK[M`UKs*$GwU#(QDXBER@CBN% Rs0~53%eYrd8mt^7Z6]iTF+(EWfJ9zaK-i?TV.C\y -------------------------------------------------------- 128 bit encrypted signature, crack if you can

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups