Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System.Diagnostics;
- ProcessStartInfo info = new ProcessStartInfo();
- info.Verb = "print";
- info.FileName = "C:\\Temp\\abcde.pdf";
- info.CreateNoWindow = true;
- info.WindowStyle = ProcessWindowStyle.Hidden;
- Process p = new Process();
- p.StartInfo = info;
- p.Start();
- p.WaitForInputIdle();
- System.Threading.Thread.Sleep(3000);
- if (false == p.CloseMainWindow()) //if (!p.CloseMainWindow())
- p.Kill();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement