private void Load1(int PCode) { JDriverLog objDriveLog = new JDriverLog(); objDriveLog.GetData(PCode); txtEventDate.Text = objDriveLog.EventDate.ToString(); JcmbLogType.Text = objDriveLog.LogType.ToString(); }
private int Save() { JDriverLog objAutoDefine = new JDriverLog(); SetData(objAutoDefine); if (State == ClassLibrary.JFormState.Insert) { Code = objAutoDefine.Insert(); } else if (State == ClassLibrary.JFormState.Update) { objAutoDefine.Update(); } State = ClassLibrary.JFormState.Update; return(Code); }
private void SetData(JDriverLog Auto) { Auto.Code = Code; Auto.EventDate = DateTime.Parse(txtEventDate.Text); Auto.LogType = (int)JcmbLogType.SelectedValue; }