Library tutorials & articles

Launching a process from Windows Forms

Introduction

I wanted to launch a script from a Windows Form application and display the standard output in a text box as the process was running.  Surely you're not surprised to learn that multithreading is involved.  It turns out you'll have at least four threads running to do this simple task.  To keep things simple and sane, I've reused code from other another source, so I must first give credit to the MSDN article "Give Your .NET-based Application a Fast and Responsive UI with Multiple Threads"  by I.D. Griffiths.  I highly suggest reading this article for more background on multithreading in Windows Forms applications.  Thanks also to Chad Christensen for his suggestions in using a RichTextBox.

Sample Image - LaunchProcess.png

Comments

  1. 10 Apr 2004 at 11:06

    Perhaps you can use this software:
    http://www.accusoft.com/imaging/imagegear/ig_formats.asp


    Regards,
    Magnus Strand

  2. 22 Mar 2004 at 11:28
    hi
    i want to convert a postscript file to image with visual c# .net.
    who can help me?
  3. 01 Jan 1999 at 00:00

    This thread is for discussions of Launching a process from Windows Forms.

Leave a comment

Sign in or Join us (it's free).

Mike Mayer Mike Mayer is a Microsoft MVP in Visual C#.

We'd love to hear what you think! Submit ideas or give us feedback