Procedure

TfrmRemCoverSheet.cbxUserChange

Module

fRemCoverSheet

Last Modified

7/15/2014 3:26:38 PM

Visibility

Public/Published

Owner

TfrmRemCoverSheet

Declaration

procedure cbxUserChange(Sender: TObject);

Calls Hierarchy


TfrmRemCoverSheet.cbxUserChange
 ├TfrmRemCoverSheet.GetUserInfo
 │ └UserDivClassInfo
 ├TfrmRemCoverSheet.GetExternalName
 │ └GetNameFromList
 │   └ExternalName
 └TfrmRemCoverSheet.cbxDropDownClose
   ├TfrmRemCoverSheet.UpdateView
   │ └TfrmRemCoverSheet.GetCurrent
   │   └TfrmRemCoverSheet.GetCoverSheetLvlData
   │     └GetCoverSheetLevelData
   └TfrmRemCoverSheet.cbEditLevelClick
     ├TfrmRemCoverSheet.GetExternalName...
     ├TfrmRemCoverSheet.SetButtonHints
     ├TfrmRemCoverSheet.UpdateView...
     └TfrmRemCoverSheet.UpdateMasterListView
       ├TfrmRemCoverSheet.GetCurrent...
       └TfrmRemCoverSheet.UpdateButtons
         ├TfrmRemCoverSheet.GetCurrent...
         ├TfrmRemCoverSheet.GetIndex
         └TfrmRemCoverSheet.LockButtonUpdate
           ├TfrmRemCoverSheet.btnLockClick
           │ └TfrmRemCoverSheet.ChangeStatus
           │   ├TfrmRemCoverSheet.GetCurrent...
           │   ├TfrmRemCoverSheet.GetIndex
           │   ├TfrmRemCoverSheet.MarkListAsChanged
           │   │ └TfrmRemCoverSheet.UpdateView...
           │   ├TfrmRemCoverSheet.SetupItem
           │   └TfrmRemCoverSheet.LockButtonUpdate...
           └TfrmRemCoverSheet.btnAddClick
             └TfrmRemCoverSheet.ChangeStatus...

Calls

Name Declaration Comments
TfrmRemCoverSheet.cbxDropDownClose procedure cbxDropDownClose(Sender: TObject); -
TfrmRemCoverSheet.GetExternalName function GetExternalName(Level: TRemCoverDataLevel; IEN: Int64): string; -
TfrmRemCoverSheet.GetUserInfo procedure GetUserInfo(AUser: Int64); -


Source

711   procedure TfrmRemCoverSheet.cbxUserChange(Sender: TObject);
712   var
713     NewVal, idx: integer;
714   
715   begin
716     FCurUser := cbxUser.ItemIEN;
717     If FCurUser < 1  then   //No value in User combobox
718     begin
719       sbCopyLeft.Enabled := false;
720       sbCopyRight.Enabled := false;
721       FSelection := false;
722     end
723     else
724       FSelection := true;
725     GetUserInfo(FCurUser);
726     idx := FUserInfo.IndexOfPiece(DivisionCode);
727     if idx >= 0 then
728     begin
729       NewVal := StrToIntDef(Piece(FUserInfo[idx],U,2),0);
730       if NewVal <> FCurDiv then
731       begin
732         FCurDiv := NewVal;
733         cbxDivision.InitLongList(GetExternalName(dlDivision, NewVal));
734         cbxDivision.SelectByIEN(NewVal);
735       end;
736     end;
737     idx := FUserInfo.IndexOfPiece(ServiceCode);
738     if idx >= 0 then
739     begin
740       NewVal := StrToIntDef(Piece(FUserInfo[idx],U,2),0);
741       if NewVal <> FCurSer then
742       begin
743         FCurSer := NewVal;
744         cbxService.InitLongList(GetExternalName(dlService, NewVal));
745         cbxService.SelectByIEN(NewVal);
746       end;
747     end;
748     FCurClass := 0;
749     cbxClass.ItemIndex := -1;
750     FUpdatePending := cbUser;
751     if not cbxUser.DroppedDown then
752       cbxDropDownClose(nil);
753   end;