private void btnSelect_Click(object sender, EventArgs e) { if (CheckGxObjectFilter(_filter)) { _workspace = GxDialogHelper.SelectWorkspaceDialog(); if (_workspace != null) { _fileName = _workspace.PathName; txtPath.Text = _fileName; } } else { OpenFileDialog dialog = new OpenFileDialog(); dialog.Multiselect = false; dialog.Title = @"请选择文件"; dialog.Filter = _filter; if (dialog.ShowDialog() == DialogResult.OK) { _fileName = dialog.FileName; txtPath.Text = _fileName; } } }
private void btnSelectGDB_Click(object sender, EventArgs e) { _targetWorkspace = GxDialogHelper.SelectWorkspaceDialog(); if (_targetWorkspace == null) { return; } txtGDBPath.Text = _targetWorkspace.PathName; }