private void OpenSubjectDetailWindow(string mode, string title)
 {
     var win = GetSelectedSubject();
     
     if (win == null && mode != FormModes.New)
     {
         Message(MessageTypes.Error, "Please Select to " + mode + " Staff Detail");
         return;
     }
     if(FormModes.New == mode)
     {
         win = new Subject();
     }
     var view = new ucSubjectDetailView(mode, win.SubjectID);
     view.ParentContainer = this;
     OpenPopUp(view, title, 400, 300);
 }
        private void OpenSubjectDetailWindow(string mode, string title)
        {
            var win = GetSelectedSubject();

            if (win == null && mode != FormModes.New)
            {
                Message(MessageTypes.Error, "Please Select to " + mode + " Staff Detail");
                return;
            }
            if (FormModes.New == mode)
            {
                win = new Subject();
            }
            var view = new ucSubjectDetailView(mode, win.SubjectID);

            view.ParentContainer = this;
            OpenPopUp(view, title, 400, 300);
        }