The following 2 lines open a text file in notepad and then close notepad:
System.Diagnostics.Process pr =
System.Diagnostics.Process.Start("c:\\windows\\system32\\notepad.exe","c:\\x.txt");
pr.CloseMainWindow();
But, the following 2 lines open a pdf file in the Acrobat reader, which
remains open:
System.Diagnostics.Process pr =
System.Diagnostics.Process.Start("c:\\program files\\adobe\\acrobat
6.0\\reader\\acrord32.exe",@"/t ""c:\exportfiles\d.pdf"" ""HP LaserJet 3300
Series PCL 6"" ""HP LaserJet 3300 Series PCL 6"" ""DOT4_001""");
pr.CloseMainWindow();
How can I close the Acrobat reader?