private void Add_Click(object sender, EventArgs e) { Add_Command command = new Add_Command(configService, null); command.ShowDialog(); if (command.CommandActionConfig != null) { source.Add(command.CommandActionConfig); source.ResetCurrentItem(); } }
private void Edit_Click(object sender, EventArgs e) { CommandActionConfig commandConfig = this.configService.Get <CommandActionConfig>(typeof(CommandActionConfig).FullName, listBox1.SelectedValue as string); Add_Command command = new Add_Command(configService, commandConfig); command.ShowDialog(); if (command.CommandActionConfig != null) { source.ResetCurrentItem(); } }
private void Edit_Click(object sender, EventArgs e) { CommandActionConfig commandConfig = this.configService.Get<CommandActionConfig>(typeof(CommandActionConfig).FullName, listBox1.SelectedValue as string); Add_Command command = new Add_Command(configService, commandConfig); command.ShowDialog(); if (command.CommandActionConfig != null) { source.ResetCurrentItem(); } }