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. Visual Basic
  4. Print Dialog Print to file

Print Dialog Print to file

Scheduled Pinned Locked Moved Visual Basic
2 Posts 2 Posters 0 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.
  • G Offline
    G Offline
    gthompson2005
    wrote on last edited by
    #1

    Hey I know this has gotta be simple PrintDocument1.PrinterSettings.PrintToFile = True PrintDocument1.Print() I want to either set the file to have it print to, or get the file name that was typed in. Thanks in advance

    D 1 Reply Last reply
    0
    • G gthompson2005

      Hey I know this has gotta be simple PrintDocument1.PrinterSettings.PrintToFile = True PrintDocument1.Print() I want to either set the file to have it print to, or get the file name that was typed in. Thanks in advance

      D Offline
      D Offline
      Dave Kreskowiak
      wrote on last edited by
      #2

      All your doing by setting .PrintToFIle to Ture is enabling the little check box on the dialog that allows the user to select printing to a file. The only way your going to be able to get a filename to print to is to build a dialog yourself or use a SaveDialog. Then you'll have to handle outputting the text to the file. You can't "print" to the filename you get. Unfortunately, the Print To File functionality doesn't work. I'm hoping it'll be fixed in the next service pack for the .NET Framework, if not in .NET 2.0. RageInTheMachine9532 "...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome

      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