private void OnBrowseFile(object sender, EventArgs e) { try { OpenFileDialog fd = new OpenFileDialog { Filter = "Picador file|*.des|Autocad dxf|*.dxf|All Files|*.*" }; if (DialogResult.OK == fd.ShowDialog()) { FormBrowseFile form = new FormBrowseFile(fd.FileName); form.ShowDialog(); } } catch (Exception ex) { _log.Error(ex.ToString()); } }
private void toolStripMenuItemBrowseFile_Click(object sender, EventArgs e) { try { OpenFileDialog fd = new OpenFileDialog(); fd.Filter = "Picador file|*.des|Autocad dxf|*.dxf|All Files|*.*"; if (DialogResult.OK == fd.ShowDialog()) { FormBrowseFile form = new FormBrowseFile(fd.FileName); form.ShowDialog(); } } catch (Exception ex) { Debug.Fail(ex.ToString()); _log.Error(ex.ToString()); } }