Exemplo n.º 1
0
 private void coldBirthday_OnAM_FieldEdit(object sender, WindowActionsEventArgs e)
 {
     #region Actions
     e.Handled = true;
     if (!Sal.IsNull(coldBirthday))
     {
         DbPLSQLBlock(cSessionManager.c_hSql, "SELECT TRUNC(Months_between(sysdate, to_date('" + coldBirthday.Text + "','yyyy-mm-dd'))/12) INTO :i_hWndFrame.colnAge FROM DUAL");
         this.colnAge.EditDataItemSetEdited();
         this.colnAge.Enabled = false;
     }
     else
     {
         this.colnAge.Clear();
     }
     #endregion
 }
Exemplo n.º 2
0
 public virtual SalBoolean CheckPassword()
 {
     #region Actions
     using (new SalContext(this))
     {
         if (sOldPasswordInput.Text != sOldpassword)
         {
             this.sOldPasswordInput.Focus();
             Ifs.Fnd.ApplicationForms.Int.AlertBox(Properties.Resources.TEXT_PasswordNotSame, Ifs.Fnd.ApplicationForms.Properties.Resources.CAPTION_Error, Ifs.Fnd.ApplicationForms.Const.WARNING_Ok);
             return(false);
         }
         else if (Sal.IsNull(this.sNewPassword))
         {
             this.sNewPassword.Focus();
             Ifs.Fnd.ApplicationForms.Int.AlertBox(Properties.Resources.TEXT_PasswordMustInput, Ifs.Fnd.ApplicationForms.Properties.Resources.CAPTION_Error, Ifs.Fnd.ApplicationForms.Const.WARNING_Ok);
             return(false);
         }
         else
         {
             return(true);
         }
     }
     #endregion
 }