C# .NET - How to open a image in ms-paint using windows application?

Asked By Eswaran Radhakrishnan on 11-Aug-08 06:14 AM
    Hi all,
I have windows form with two image control and two button one for save and another one for LoadImage.After form loaded then if i click the LoadImage button then the image should be loaded on the image control. If I double click the image then the image should be open in ms-paint for modiciation.
After modification if I click the save button it should be saved as iamge.

How to do that in windows application?
Thanks
R. Eswaran.

Use this... - Atul Shinde replied to Eswaran Radhakrishnan on 11-Aug-08 06:24 AM

U can use process.start to open mspaint application. Provide FileName while opening that application.

Check this - san san replied to Eswaran Radhakrishnan on 11-Aug-08 06:27 AM

Hi

Try the following code.
This works..

Image img = Image.FromFile(@"E:\MyImage.gif");
            img.Tag = @"E:\MyImage.gif";
            System.Diagnostics.ProcessStartInfo info = new System.Diagnostics.ProcessStartInfo();
            info.FileName = ("mspaint.exe");
            info.Arguments = img.Tag.ToString(); // returns full path and name
            System.Diagnostics.Process p1 = System.Diagnostics.Process.Start(info);
         
Hope this helps
SAN  

image - sundar k replied to Eswaran Radhakrishnan on 11-Aug-08 07:16 AM

What you can do is to place a double click event for your image/picture box control and in that you can invoke mspaint.exe using Process.Start with parameter as the loaded image file(full path). Process.Start will open up mspaint application, you can make changes to the image and can save the image seperately. If you want to refresh the saved image again to your picturebox/image, then probably you will have to reload the image.
But, I need to modify the image as we displayed in Image Box.. - Eswaran Radhakrishnan replied to san san on 12-Aug-08 05:59 AM
hi,
It opens ms-paint application speartely, but I need it wehn I double click on the particular iamge the ms-paint application should be opens within the form and then I need to modify the image as we show in the picture box. I need to modify the image as displayed in picture box.

Thanks
R. Eswaran.
how to open , Edit and save image in paint using c# windows application
raaji karivedha replied to Eswaran Radhakrishnan on 06-Oct-08 06:38 AM
how to open , Edit and save image in paint using c# windows application
a - ala gesan replied to Eswaran Radhakrishnan on 03-Feb-09 02:58 AM
a