473,396 Members | 2,026 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Printing a series of PDF files

Hello!

I want to print out a series of PDF files. I need to print them in a
controlled order.

I have tried to use this funktion, see below, but it stops on
WaitForExit(). The first file prints but then Acrobat reader doesn't shut
down! I also get a new window with an empty Acrobat reader??

Anyone that can figure out what's wrong, or have a working way of printing
out PDF1 to PDF5 in order???

// Anders
--
Function MyPrint(ByVal Fil)
Dim startinfo As New System.Diagnostics.ProcessStartInfo
Dim myprocess As New System.Diagnostics.Process

startinfo.FileName = Fil
startinfo.CreateNoWindow = True
startinfo.Verb = "print"

' start the printout
myprocess = myprocess.Start(startinfo)

' wait for the process to end, i.e. for the document to be printed
myprocess.WaitForExit()

' release
myprocess.Close()
myprocess = Nothing
startinfo = Nothing

End Function

Crossposted to: microsoft.public.dotnet.languages.vb,microsoft.pub lic.dotnet.general
Replies will go to: microsoft.public.dotnet.languages.vb
Jul 21 '05 #1
0 961

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Mr. B | last post by:
This is driving me NUTZ!!! I've been screwing around on this for a week now. And I have tried to find examples similar to what I have (nada). Got lots of streaming a TXT file... bah! I am...
4
by: Jeff Harbin | last post by:
I've got an ACCESS 2000 application that I'm developing. One of the outputs of this app will be to generate a series of 'jobs' which corresponds to a record in the database. Each record will be...
6
by: mg | last post by:
The following .exe and its parameters work correctly from the command prompt (it prints x.pdf without prompting the user. acrord32.exe /t "c:\exportfiles\x.pdf" "HP LaserJet 3300 Series PCL 6"...
0
by: Anders Eriksson | last post by:
Hello! I want to print out a series of PDF files. I need to print them in a controlled order. I have tried to use this funktion, see below, but it stops on WaitForExit(). The first file...
0
by: notregister | last post by:
Ji, i tried to use tcpclient to send a series of PCL command to a printer, but after going thru this, it print out a series of junk...the same series work well with another code i written for...
1
by: hamil | last post by:
I am trying to print a graphic file (tif) and also use the PrintPreview control, the PageSetup control, and the Print dialog control. The code attached is a concatination of two examples taken out...
0
by: Bhaskar | last post by:
Hi all, Problem: OS : Win XP Platform: VB.NET(Web Application) My application enumerates all the printers in the network. Currently there are only 2 network printers here. 1.EPSON TM...
8
by: Rick Lederman | last post by:
I am using a PrintDocument and PrintDialog to print. The first time that I print it works, but when I try to print a second time without exiting the entire program I get an...
4
by: Chris Seymour | last post by:
Hi All, I am working on a python script for my colleague that will walk a directory and search in the different files for a specific string. These pieces I am able to do. What my colleague wants...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.