Click here to Skip to main content
15,881,882 members
Please Sign up or sign in to vote.
1.00/5 (2 votes)
See more:
how to make code C# for menustrip save open file.I want to make program editor drawing.
this my program for new file

C#
private void newToolStripMenuItem_Click(object sender, EventArgs e)
      {
          var paint = new Form();
          paint.Show();


      }
Posted
Comments
Michael J. Eber 11-Feb-13 14:29pm    
What have you tried so far? Anything at all? Have you looked at the FileSaveDialog?

1 solution

OpenFileDialog :
C#
private void openFIleToolStripMenuItem_Click(object sender, EventArgs e){
            string ChosenFile = "";
            openFileDialog1.FileName = "";
            //you can add .jpeg , etc.
            openFileDialog1.Filter = "png(*.png)|*.png|ALL Files(*.*)|*.*";
            ChosenFile = openFileDialog1.FileName;
            if (openFileDialog1.ShowDialog() == System.Windows.Forms.DialogResult.OK)
            {
               //here you put your code to show picture in picture view(whatever you use)
               // also in some textbox you can show path to picture..
               //textBox1.Text = openFileDialog1.FileName;
            }
}

SaveASFileDialog:

C#
your code.ShowSaveAsDialog();
 
Share this answer
 
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900