Function

TfrmODMeds.ValFor

Module

fODMeds

Last Modified

7/15/2014 3:26:42 PM

Comments

General Functions - get & set cell values

 Contents of grid cells  (Only the first tab piece for each cell is drawn)
    Dosage    <TAB> DosageFields
    RouteText <TAB> IEN^RouteName^Abbreviation
    Schedule  <TAB> (nothing)
    Duration  <TAB> Duration^Units

Visibility

Private

Owner

TfrmODMeds

Declaration

function ValFor(FieldID, ARow: Integer): string;

Called-By Hierarchy


                         TfrmODMeds.ValFor
                     TfrmODMeds.Validate┤ 
                TfrmODMeds.tabDoseChange┤ 
                TfrmODMeds.FormKeyDown┘ │ 
                TfrmODMeds.ControlChange┤ 
                TfrmODMeds.SetupDialog┤ │ 
                   TfrmODMeds.Validate┤ │ 
             TfrmODMeds.btnSelectClick┤ │ 
             TfrmODMeds.UMDelayClick┘ │ │ 
           TfrmODMeds.tabDoseChange...┤ │ 
             TfrmODMeds.cboRouteChange┤ │ 
           TfrmODMeds.SetOnMedSelect┘ │ │ 
            TfrmODMeds.SetupDialog┤   │ │ 
      TfrmODMeds.btnSelectClick...┤   │ │ 
       TfrmODMeds.CheckFormAltDose┘   │ │ 
       TfrmODMeds.cboDosageClick┘     │ │ 
     TfrmODMeds.cboDosageKeyUp┘       │ │ 
           TfrmODMeds.popDurationClick┤ │ 
            TfrmODMeds.cboXRouteChange┤ │ 
             TfrmODMeds.cboXRouteClick┤ │ 
            TfrmODMeds.cboXRouteExit┘ │ │ 
         TfrmODMeds.txtXDurationChange┤ │ 
         TfrmODMeds.popDurationClick┘ │ │ 
            TfrmODMeds.btnXRemoveClick┤ │ 
          TfrmODMeds.grdDosesKeyDown┘ │ │ 
       TfrmODMeds.timCheckChangesTimer┤ │ 
            TfrmODMeds.UpdateRelated┘ │ │ 
            TfrmODMeds.SetupDialog┤   │ │ 
      TfrmODMeds.btnSelectClick...┤   │ │ 
      TfrmODMeds.cboDosageClick...┤   │ │ 
        TfrmODMeds.cboDosageChange┤   │ │ 
          TfrmODMeds.cboDosageExit┤   │ │ 
       TfrmODMeds.cboScheduleClick┤   │ │ 
       TfrmODMeds.cmdAcceptClick┤ │   │ │ 
          TfrmODMeds.chkPRNClick┤ │   │ │ 
          TfrmODMeds.txtNSSClick┤ │   │ │ 
     TfrmODMeds.cboScheduleEnter┤ │   │ │ 
     TfrmODMeds.UMShowNSSBuilder┘ │   │ │ 
      TfrmODMeds.cboScheduleChange┤   │ │ 
        TfrmODMeds.txtSupplyChange┤   │ │ 
      TfrmODMeds.txtQuantityChange┤   │ │ 
           TfrmODMeds.grdDosesExit┤   │ │ 
       TfrmODMeds.cboXDosageChange┤   │ │ 
        TfrmODMeds.cboXDosageClick┤   │ │ 
       TfrmODMeds.cboXDosageExit┤ │   │ │ 
      TfrmODMeds.cboXDosageKeyUp┘ │   │ │ 
         TfrmODMeds.cboXDosageExit┤   │ │ 
     TfrmODMeds.cboXScheduleChange┤   │ │ 
          TfrmODMeds.txtNSSClick┘ │   │ │ 
      TfrmODMeds.cboXScheduleClick┤   │ │ 
         TfrmODMeds.chkXPRNClick┤ │   │ │ 
     TfrmODMeds.pnlXScheduleExit┘ │   │ │ 
       TfrmODMeds.pnlXScheduleExit┤   │ │ 
  TfrmODMeds.txtXDurationChange...┤   │ │ 
       TfrmODMeds.pnlXDurationExit┤   │ │ 
            TfrmODMeds.chkPRNClick┤   │ │ 
        TfrmODMeds.cboScheduleExit┤   │ │ 
         TfrmODMeds.cboDosageKeyUp┤   │ │ 
        TfrmODMeds.cboXDosageKeyUp┘   │ │ 
         TfrmODMeds.chkPtInstructClick┤ │ 
            TfrmODMeds.chkDoseNowClick┤ │ 
          TfrmODMeds.SetOnQuickOrder┘ │ │ 
            TfrmODMeds.SetupDialog┤   │ │ 
      TfrmODMeds.btnSelectClick...┘   │ │ 
                TfrmODMeds.chkPRNClick┤ │ 
         TfrmODMeds.cboXSequenceChange┤ │ 
           TfrmODMeds.txtRefillsChange┘ │ 
               TfrmODMeds.DurationToDays┤ 
       TfrmODMeds.UpdateSupplyQuantity┘ │ 
  TfrmODMeds.timCheckChangesTimer...┘   │ 
                   TfrmODMeds.ShowEditor┤ 
            TfrmODMeds.pnlFieldsResize┤ │ 
      TfrmODMeds.ShowControlsComplex┘ │ │ 
          TfrmODMeds.ShowMedFields┤   │ │ 
          TfrmODMeds.SetupDialog┤ │   │ │ 
    TfrmODMeds.btnSelectClick...┘ │   │ │ 
       TfrmODMeds.tabDoseChange...┘   │ │ 
          TfrmODMeds.grdDosesMouseDown┤ │ 
           TfrmODMeds.grdDosesKeyPress┤ │ 
            TfrmODMeds.btnXInsertClick┘ │ 
          TfrmODMeds.grdDosesKeyDown┘   │ 
           TfrmODMeds.pnlXAdminTimeClick┤ 
        TfrmODMeds.txtXDurationChange...┤ 
                  GetComplexDoseSchedule┤ 
                    TfrmODMeds.ValueOf┘ │ 
               TfrmODMeds.InitDialog┤   │ 
             TfrmODMeds.FormCreate┘ │   │ 
        TfrmODMeds.SetOnMedSelect...┤   │ 
       TfrmODMeds.SetOnQuickOrder...┤   │ 
        TfrmODMeds.cboDosageClick...┤   │ 
     TfrmODMeds.QuantityMessageCheck┤   │ 
        TfrmODMeds.cboXDosageEnter┤ │   │ 
TfrmODMeds.pnlXDurationButtonEnter┤ │   │ 
         TfrmODMeds.cboXRouteEnter┤ │   │ 
      TfrmODMeds.cboXSequenceEnter┤ │   │ 
      TfrmODMeds.cboXScheduleEnter┘ │   │ 
            TfrmODMeds.OutpatientSig┤   │ 
       TfrmODMeds.ControlChange...┘ │   │ 
             TfrmODMeds.InpatientSig┤   │ 
       TfrmODMeds.ControlChange...┘ │   │ 
         TfrmODMeds.ControlChange...┤   │ 
       TfrmODMeds.cboXDosageClick...┤   │ 
  TfrmODMeds.timCheckChangesTimer...┘   │ 
                GetComplexDoseScheduleEX┤ 
                 TfrmODMeds.ValueOf...┘ │ 
           TfrmODMeds.UpdateStartExpires┤ 
                TfrmODMeds.SetupDialog┤ │ 
         TfrmODMeds.SetOnQuickOrder...┤ │ 
           TfrmODMeds.tabDoseChange...┤ │ 
      TfrmODMeds.cboXScheduleChange...┤ │ 
       TfrmODMeds.cboXScheduleClick...┤ │ 
    TfrmODMeds.timCheckChangesTimer...┤ │ 
                TfrmODMeds.chkPRNClick┤ │ 
         TfrmODMeds.cboXSequenceChange┘ │ 
               TfrmODMeds.cmdAcceptClick┤ 
           TfrmODMeds.cboXSequenceChange┘ 

Called-By

Name Declaration Comments
TfrmODMeds.cboXSequenceChange procedure cboXSequenceChange(Sender: TObject); -
TfrmODMeds.cmdAcceptClick procedure cmdAcceptClick(Sender: TObject); -
TfrmODMeds.ControlChange procedure ControlChange(Sender: TObject); -
TfrmODMeds.DurationToDays function DurationToDays: Integer; -
GetComplexDoseSchedule function GetComplexDoseSchedule: string; -
GetComplexDoseScheduleEX function GetComplexDoseScheduleEX: string; -
TfrmODMeds.pnlXAdminTimeClick procedure pnlXAdminTimeClick(Sender: TObject); -
TfrmODMeds.ShowEditor procedure ShowEditor(ACol, ARow: Integer; AChar: Char); -
TfrmODMeds.tabDoseChange procedure tabDoseChange(Sender: TObject); -
TfrmODMeds.txtXDurationChange procedure txtXDurationChange(Sender: TObject); -
TfrmODMeds.UpdateStartExpires procedure UpdateStartExpires(const CurSchedule: string); -
TfrmODMeds.Validate procedure Validate(var AnErrMsg: string); override; -


Source

3237  function TfrmODMeds.ValFor(FieldID, ARow: Integer): string;
3238  { Contents of grid cells  (Only the first tab piece for each cell is drawn)
3239      Dosage    <TAB> DosageFields
3240      RouteText <TAB> IEN^RouteName^Abbreviation
3241      Schedule  <TAB> (nothing)
3242      Duration  <TAB> Duration^Units }
3243  begin
3244    Result := '';
3245    if (ARow < 1) or (ARow >= grdDoses.RowCount) then Exit;
3246    with grdDoses do
3247      case FieldID of
3248      COL_DOSAGE    : Result := Piece(Cells[COL_DOSAGE,   ARow], TAB, 1);
3249      COL_ROUTE     : Result := Piece(Cells[COL_ROUTE,    ARow], TAB, 1);
3250      COL_SCHEDULE  : Result := Piece(Cells[COL_SCHEDULE, ARow], TAB, 1);
3251      COL_DURATION  : Result := Piece(Cells[COL_DURATION, ARow], TAB, 1);
3252      COL_SEQUENCE  : Result := Piece(Cells[COL_SEQUENCE, ARow], TAB, 1);
3253      VAL_DOSAGE    : Result := Piece(Cells[COL_DOSAGE,   ARow], TAB, 2);
3254      VAL_ROUTE     : Result := Piece(Cells[COL_ROUTE,    ARow], TAB, 2);
3255      VAL_SCHEDULE  : Result := Piece(Cells[COL_SCHEDULE, ARow], TAB, 1);
3256      VAL_DURATION  : Result := Piece(Cells[COL_DURATION, ARow], TAB, 1);
3257      VAL_ADMINTIME : Result := Piece(Cells[COL_ADMINTIME, ARow], TAB, 1);
3258      VAL_SEQUENCE  : Result := Piece(Cells[COL_SEQUENCE, ARow], TAB, 1);
3259      VAL_CHKXPRN   : Result := Cells[COL_CHKXPRN, ARow];
3260      end;
3261  end;