Exemplo n.º 1
0
        private void Status_EditValueChanged(object sender, EventArgs e)
        {
            GridLookUpEdit editor = sender as GridLookUpEdit;

            string colorCode = "";

            if (editor.Properties.View.FocusedRowHandle > -1)
            {
                colorCode = editor.Properties.View.GetFocusedRowCellValue("ColorCode").ToString();
                editor.Properties.Appearance.BackColor = Color.FromName(colorCode);
            }

            bool     isDisputed = editor.EditValue.ToString() == "DISP";
            RqmtType rqmtType   = (RqmtType)Enum.Parse(typeof(RqmtType), editor.Tag.ToString(), true);

            SetEditFields(rqmtType, isDisputed);
        }
Exemplo n.º 2
0
 private void SetEditFields(RqmtType ARqmtType, bool ADisputed)
 {
     switch (ARqmtType)
     {
     case RqmtType.Sempra:
         if (ADisputed)
         {
             comboSempraDispReason.Location = new System.Drawing.Point(EDIT_FIELD_X, comboSempraDispReason.Location.Y);
             comboSempraDispReason.TabStop  = true;
             memoexedSempra.Location        = new System.Drawing.Point(NOT_ACTIVE_X, memoexedSempra.Location.Y);
             memoexedSempra.TabStop         = false;
         }
         else
         {
             comboSempraDispReason.Location = new System.Drawing.Point(NOT_ACTIVE_X, comboSempraDispReason.Location.Y);
             comboSempraDispReason.TabStop  = false;
             memoexedSempra.Location        = new System.Drawing.Point(EDIT_FIELD_X, memoexedSempra.Location.Y);
             memoexedSempra.TabStop         = true;
         }
         break;
     }
 }
Exemplo n.º 3
0
 private void SetEditFields(RqmtType ARqmtType, bool ADisputed)
 {
    switch (ARqmtType)
    {
       case RqmtType.Sempra:
          if (ADisputed)
          {
             comboSempraDispReason.Location = new System.Drawing.Point(EDIT_FIELD_X, comboSempraDispReason.Location.Y);
             comboSempraDispReason.TabStop = true;
             memoexedSempra.Location = new System.Drawing.Point(NOT_ACTIVE_X, memoexedSempra.Location.Y);
             memoexedSempra.TabStop = false;
          }
          else
          {
             comboSempraDispReason.Location = new System.Drawing.Point(NOT_ACTIVE_X, comboSempraDispReason.Location.Y);
             comboSempraDispReason.TabStop = false;                  
             memoexedSempra.Location = new System.Drawing.Point(EDIT_FIELD_X, memoexedSempra.Location.Y);
             memoexedSempra.TabStop = true;
          }
          break;
    }
 }