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. Catch printing any document from any application (word, excel, pdf,...) to show printing options

Catch printing any document from any application (word, excel, pdf,...) to show printing options

Scheduled Pinned Locked Moved Visual Basic
careerquestion
4 Posts 4 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.
  • E Offline
    E Offline
    edmonson
    wrote on last edited by
    #1

    Hi, I'm developing a cybercafe app. and i need to detect printing process from other aplications(Word,Acrobat,...) I need to send the job to any printer and select if it may be in color or BW. User doesn't use printer properties directly from its application(word,excel,...). He clicks on printing button directly. My trouble is catch this action to force him to show the destination printer and job color mode. I've been working with system.printing namespace to control the spooler: - When a new job arrives, I stop it. I obtain information about pages, printer,... but if I change any parameters like coloroutput property, it has no efect on the job when I resume it to finish the printing process (restart the job fails too) Any Idea ? Regards

    D H S 3 Replies Last reply
    0
    • E edmonson

      Hi, I'm developing a cybercafe app. and i need to detect printing process from other aplications(Word,Acrobat,...) I need to send the job to any printer and select if it may be in color or BW. User doesn't use printer properties directly from its application(word,excel,...). He clicks on printing button directly. My trouble is catch this action to force him to show the destination printer and job color mode. I've been working with system.printing namespace to control the spooler: - When a new job arrives, I stop it. I obtain information about pages, printer,... but if I change any parameters like coloroutput property, it has no efect on the job when I resume it to finish the printing process (restart the job fails too) Any Idea ? Regards

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

      Once you start a print job, it cannot be changed. The spooling data is specifically for the target printer and is written with the parameters chosen in mind. Once the job starts, it's too late to make any changes. The only thing you can do is pause or cancel the job.

      A guide to posting questions on CodeProject[^]
      Dave Kreskowiak Microsoft MVP Visual Developer - Visual Basic
           2006, 2007, 2008
      But no longer in 2009...

      1 Reply Last reply
      0
      • E edmonson

        Hi, I'm developing a cybercafe app. and i need to detect printing process from other aplications(Word,Acrobat,...) I need to send the job to any printer and select if it may be in color or BW. User doesn't use printer properties directly from its application(word,excel,...). He clicks on printing button directly. My trouble is catch this action to force him to show the destination printer and job color mode. I've been working with system.printing namespace to control the spooler: - When a new job arrives, I stop it. I obtain information about pages, printer,... but if I change any parameters like coloroutput property, it has no efect on the job when I resume it to finish the printing process (restart the job fails too) Any Idea ? Regards

        H Offline
        H Offline
        Henry Minute
        wrote on last edited by
        #3

        After reading Dave's reply, it has occurred to me that you might be able to create a new print job using those parts from the original that you want to retain and the new ones that you want to use then deleting the original. I have no idea how you would do that but if it were me, that is what I would explore. :)

        Henry Minute Do not read medical books! You could die of a misprint. - Mark Twain Girl: (staring) "Why do you need an icy cucumber?" “I want to report a fraud. The government is lying to us all.”

        1 Reply Last reply
        0
        • E edmonson

          Hi, I'm developing a cybercafe app. and i need to detect printing process from other aplications(Word,Acrobat,...) I need to send the job to any printer and select if it may be in color or BW. User doesn't use printer properties directly from its application(word,excel,...). He clicks on printing button directly. My trouble is catch this action to force him to show the destination printer and job color mode. I've been working with system.printing namespace to control the spooler: - When a new job arrives, I stop it. I obtain information about pages, printer,... but if I change any parameters like coloroutput property, it has no efect on the job when I resume it to finish the printing process (restart the job fails too) Any Idea ? Regards

          S Offline
          S Offline
          Steven J Jowett
          wrote on last edited by
          #4

          You could create a Virtual Printer (like those that create PDF file), and set it as the default printer. The virtual printer could then decide how to handle the print job. I am intending to write a similar Virtual Printer, but for processing emails. I cannot tell you how to start, because I am that stage myself.

          Steve Jowett ------------------------- Real programmers don't comment their code. If it was hard to write, it should be hard to read.

          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