private void btnBrowse_Click(object sender, EventArgs e) { string sProg = ""; Lime49.OpenFileDialog ofd = new Lime49.OpenFileDialog(); ofd.Filter = "exe";// "applications|*.exe|all files|*.*"; if (ofd.ShowDialog() == DialogResult.OK) { sProg = ofd.SelectedFile; if(System.IO.File.Exists(sProg)) txtProgramLocation.Text = sProg; } ofd.Dispose(); }
private void mnuSave_Click(object sender, EventArgs e) { updateSettings(); string sXmlFile = ""; Lime49.OpenFileDialog ofd = new Lime49.OpenFileDialog(); ofd.Filter = "xml";// "applications|*.exe|all files|*.*"; if (ofd.ShowDialog() == DialogResult.OK) { sXmlFile = ofd.SelectedFile; _settings.writeXML(sXmlFile); } ofd.Dispose(); }
private void btnBrowse_Click(object sender, EventArgs e) { string sProg = ""; Lime49.OpenFileDialog ofd = new Lime49.OpenFileDialog(); ofd.Filter = "exe";// "applications|*.exe|all files|*.*"; if (ofd.ShowDialog() == DialogResult.OK) { sProg = ofd.SelectedFile; if (System.IO.File.Exists(sProg)) { txtProgramLocation.Text = sProg; } } ofd.Dispose(); }
private void mnuLoad_Click(object sender, EventArgs e) { string sXmlFile = ""; Lime49.OpenFileDialog ofd = new Lime49.OpenFileDialog(); ofd.Filter = "xml";// "applications|*.exe|all files|*.*"; if (ofd.ShowDialog() == DialogResult.OK) { sXmlFile = ofd.SelectedFile; if (System.IO.File.Exists(sXmlFile)) { rdp_settings rdpsett = rdp_settings.loadSettings(sXmlFile); if (rdpsett != null) { _settings = rdpsett; updateForm(); } } } ofd.Dispose(); }