Exemplo n.º 1
0
        private void OpenEducationDetailWindow(string mode, string title)
        {
            var win = (Education)gvEducationListView.SelectedItem;

            if (win == null && mode != FormModes.New)
            {
                Message(MessageTypes.Error, "Please Select to edit");
                return;
            }
            ucEducationDetailView view;

            if (win != null && win.EducationID == 0)
            {
                view = new ucEducationDetailView(FormModes.New, win.EducationID, win);
            }
            else
            {
                if (win == null)
                {
                    win = new Education();
                }
                view = new ucEducationDetailView(FormModes.New, win.EducationID);
            }
            view.ParentContainer = this;
            OpenPopUp(view, title, 500, 260);
        }
 private void OpenEducationDetailWindow(string mode, string title)
 {
     var win = (Education)gvEducationListView.SelectedItem;
     if (win == null && mode != FormModes.New)
     {
         Message(MessageTypes.Error, "Please Select to edit");
         return;
     }
     ucEducationDetailView view;
     if (win != null && win.EducationID == 0)
     {
         view = new ucEducationDetailView(FormModes.New, win.EducationID, win);
     }
     else
     {
         if (win == null)
         {
             win = new Education();
         }
         view = new ucEducationDetailView(FormModes.New, win.EducationID);
     }
     view.ParentContainer = this;
     OpenPopUp(view, title, 500, 260);
 }