private void cmdNova_Click(object sender, EventArgs e) {

			DataSourceEditor form = new DataSourceEditor();
			DataSource ds = form.newDataSource();

			if (ds != null) {
				project.DataSources.Add(ds);
				lstDataSources.DataSource = null;
				lstDataSources.DataSource = project.DataSources;
				lstDataSources.SelectedIndex = lstDataSources.FindString(ds.Name);
			}
		}
Ejemplo n.º 2
0
 private void cmdNewDataSource_Click(object sender, EventArgs e) {
     DataSourceEditor editor = new DataSourceEditor();
     DataSource ds = editor.newDataSource();
     if (ds != null) {
         dataSources.Add(ds);
         Rebind(lstDataSources);
         lstDataSources.SelectedItem = ds;
         lstDataSources.Focus();
         //dataSources.Save();
     }
 }