protected void EventEditButton_Click(object sender, EventArgs e) { if (EventGridView.Rows.Count == 0) { return; } if (EventGridView.SelectedIndex != -1) { ((FormView)EventDialog.FindControl("EventForm")).ChangeMode(FormViewMode.Edit); EventDialog.Caption = "Редактирование события"; EventDialog.Show(EditorMode.Edit); } }
private void ShowEventDialog(object sender, RoutedEventArgs e) { var s = new EventDialog(); s.Show(); }
protected void EventAddButton_Click(object sender, EventArgs e) { ((FormView)EventDialog.FindControl("EventForm")).ChangeMode(FormViewMode.Insert); EventDialog.Caption = "Создание события"; EventDialog.Show(EditorMode.Insert); }