Ignore:
Timestamp:
Aug 12, 2009, 7:34:51 PM (15 years ago)
Author:
Kevin Toppenberg
Message:

v1.1 Fixes Access/Verify code issues

Location:
cprs/branches/GUI-config
Files:
40 edited

Legend:

Unmodified
Added
Removed
  • cprs/branches/GUI-config/AboutU.dfm

    r476 r542  
    11object AboutForm: TAboutForm
    2   Left = 297
    3   Top = 73
     2  Left = 302
     3  Top = 173
    44  AlphaBlend = True
    55  AlphaBlendValue = 50
     
    11471147    Font.Style = []
    11481148    Lines.Strings = (
    1149       'WorldVistA Configuration Utility, v1.0'
    1150       '(c) 2008; Released under LGPL'
     1149      'WorldVistA Configuration Utility, v1.10'
     1150      '(c) 12/2008; Released under LGPL'
    11511151      'Programmed by:  Kevin Toppenberg & Eddie Hagood')
    11521152    ParentFont = False
  • cprs/branches/GUI-config/BatchAddU.dfm

    r476 r542  
    11object BatchAddForm: TBatchAddForm
    2   Left = 242
    3   Top = 151
     2  Left = 73
     3  Top = 196
    44  Width = 721
    55  Height = 480
     
    2929      713
    3030      41)
     31    object EstTimeLabel: TLabel
     32      Left = 656
     33      Top = 16
     34      Width = 48
     35      Height = 13
     36      Anchors = [akTop, akRight]
     37      Caption = '1d:23h:15'
     38    end
    3139    object ProgressBar: TProgressBar
    3240      Left = 16
    3341      Top = 8
    34       Width = 681
     42      Width = 625
    3543      Height = 25
    3644      Anchors = [akLeft, akRight]
  • cprs/branches/GUI-config/BatchAddU.pas

    r493 r542  
    2929uses
    3030  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
    31   Dialogs, StdCtrls, Buttons, Grids, ExtCtrls, ComCtrls;
     31  Dialogs, StdCtrls, Buttons, Grids, ExtCtrls, ComCtrls, DateUtils;
    3232
    3333type
     
    4646    btnAbortRegistration: TBitBtn;
    4747    SaveDialog: TSaveDialog;
     48    EstTimeLabel: TLabel;
    4849    procedure btnCreateTemplateClick(Sender: TObject);
    4950    procedure btnClearGridClick(Sender: TObject);
     
    6667    procedure ClearGrid;
    6768    procedure LoadData(fileName : string);
    68     procedure AddHeaderCol(oneEntry : string); 
     69    procedure AddHeaderCol(oneEntry : string);
    6970    procedure GetColFieldNums(List : TStringList);
    7071    function GetOneRow(row : integer; ColFields : TStringList) : string;
     72    function RowToStr(row : integer) : string;
     73    procedure AddRowFromStr(Str : string);
    7174    function RegisterOne(oneRow : string; Log : TStringList) : string;
    72     procedure DelGridRow(BatchGrid : TStringGrid; row : integer);
     75    //procedure DelGridRow(BatchGrid : TStringGrid; row : integer);
    7376  public
    7477    { Public declarations }
     
    8083implementation
    8184
    82 uses CreateTemplateU, StrUtils, ORNet, ORFn, Trpcb, FMErrorU;
     85uses CreateTemplateU, StrUtils, ORNet, ORFn,
     86     Trpcb,  //needed for .ptype types
     87     FMErrorU;
    8388
    8489const NOT_ADDED='(Not Added)';
     
    260265  end;
    261266
    262  
     267
    263268  procedure TBatchAddForm.btnDoRegistrationClick(Sender: TObject);
    264   var row : integer;
     269  var i,row : integer;
     270      FailedPatients : TStringList;
    265271      ColFields : TStringList;
    266272      onePostEntry : string;
    267       newIEN : string;
     273      RPCResult : string;
    268274      Log : TStringList;
    269       Success,Failure,PreExisting : integer;
     275      Success,Failure,PreExisting,Errors : integer;
     276      StartTime : TDateTime;
     277
     278      procedure ShowEstTime(Pct : single);
     279      var  Delta : single;
     280           EstTotalMin : Integer;
     281           s : string;
     282      begin
     283        Delta := MinuteSpan(Now,StartTime);
     284        if Pct=0 then begin
     285          EstTimeLabel.caption := '';
     286          exit;
     287        end;
     288        EstTotalMin := Round(Delta / Pct);
     289        s := '';
     290        if EstTotalMin > 1440 then begin  //extract number of days
     291          s := s + IntToStr(EstTotalMin div 1440) + 'd:';
     292          EstTotalMIn := EstTotalMin mod 1440;
     293        end;
     294        if EstTotalMin > 60 then begin  //extract number of hours
     295          if s <> '' then s := s + IntToStr(EstTotalMin div 60) + 'h:'
     296          else s := IntToStr(EstTotalMin div 60) + ':';
     297          EstTotalMIn := EstTotalMin mod 60;
     298        end;
     299        s := s + IntToStr(EstTotalMin) + ':';
     300        EstTimeLabel.Caption := s;
     301      end;
     302
    270303  begin
    271304    btnOpenDataFile.Enabled := false;
     
    274307    btnClearGrid.Enabled := False;
    275308    btnSaveGrid.Enabled := False;
    276    
     309
    277310    Log := TStringList.Create;
    278311    Success := 0;
    279312    Failure := 0;
    280313    PreExisting := 0;
     314    Errors := 0;
    281315    FMErrorForm.Memo.Lines.clear;
    282316    ColFields := TStringList.Create;
     317    FailedPatients := TStringList.Create;
    283318    GetColFieldNums(ColFields);
    284319    ProgressBar.Max := BatchGrid.RowCount-1;
    285320    FAbortRegistration := false;  //abort button can change this.
     321    StartTime := Now;
     322    EstTimeLabel.Caption := '';
    286323    for row := 2 to BatchGrid.RowCount-1 do begin
    287324      if FAbortRegistration = true then break;
    288325      ProgressBar.Position := row;
     326      if (row mod 100) = 0 then ShowEstTime(row/(BatchGrid.RowCount-1));
    289327      onePostEntry := GetOneRow(row,ColFields);
    290       newIEN := RegisterOne(onePostEntry,Log);
    291       BatchGrid.Cells[0,row] := newIEN;
    292       if newIEN = NOT_ADDED then inc(Failure)
    293       else if newIEN = ALREADY_ADDED then inc(PreExisting)
    294       else inc(Success);     
     328      RPCResult := RegisterOne(onePostEntry,Log);  //Returns: NewIEN^PrevReg^Reg'dNow^ErrorOccured
     329      BatchGrid.Cells[0,row] := Piece(RPCResult,'^',1);
     330      if Piece(RPCResult,'^',1)=NOT_ADDED then inc(Failure);
     331      if Piece(RPCResult,'^',2)='1' then inc(PreExisting);
     332      if Piece(RPCResult,'^',3)='1' then inc(Success);
     333      if Piece(RPCResult,'^',4)='1' then inc(Errors);
    295334      Application.ProcessMessages;
    296335    end;
    297336    ProgressBar.Position := 0;
    298337    ColFields.free;
    299     MessageDlg(IntToStr(Success)+' successful registrations,  '+#10+#13+
    300                IntToStr(PreExisting)+' Patients were already registered,'+#10+#13+
    301                IntToStr(Failure)+' failures.',
     338    MessageDlg(IntToStr(Success)+' successful registrations or data refresh,  '+#10+#13+
     339               IntToStr(PreExisting)+' patients were already registered,'+#10+#13+
     340               IntToStr(Errors)+' filing errors encountered (including minor errors),'+#10+#13+
     341               IntToStr(Failure)+' patients NOT registered.',
    302342               mtInformation,[mbOK],0);
     343    EstTimeLabel.Caption := '';
     344    StartTime := Now;
     345    if BatchGrid.RowCount > 1000 then ShowMessage('Will now clear out patients that have been registered.');
     346    for row := 2 to BatchGrid.RowCount-1 do begin
     347      if (BatchGrid.Cells[0,row] = NOT_ADDED) or (BatchGrid.Cells[0,row] = ADD_ROW) then begin
     348        FailedPatients.Add(RowToStr(row));
     349      end;
     350      ProgressBar.Position := row;
     351      if (row mod 100) = 0 then ShowEstTime(row/(BatchGrid.RowCount-1));
     352      Application.ProcessMessages;
     353    end;
     354    BatchGrid.RowCount := 2;
     355    ProgressBar.Max := FailedPatients.Count;
     356    StartTime := Now;
     357    for i := 0 to FailedPatients.Count-1 do begin
     358      AddRowFromStr(FailedPatients.Strings[i]);
     359      ProgressBar.Position := i;
     360      if (i mod 100) = 0 then ShowEstTime(i/(FailedPatients.Count-1));
     361      Application.ProcessMessages;
     362    end;
     363    {
    303364    for row := BatchGrid.RowCount-1 downto 2 do begin
    304365      if (BatchGrid.Cells[0,row] <> NOT_ADDED)
    305366      and (BatchGrid.Cells[0,row] <> ADD_ROW) then begin
    306         DelGridRow(BatchGrid,row);
    307       end;
    308     end;                       
     367        DelGridRow(BatchGrid,row);  // <------- this is VERY SLOW!!@#@!
     368      end;
     369      ProgressBar.Position := row;
     370      if (row mod 100) = 0 then ShowEstTime((BatchGrid.RowCount-1-row)/(BatchGrid.RowCount-1));
     371      Application.ProcessMessages;
     372    end;
     373    }
     374    EstTimeLabel.Caption := '';
    309375    if Log.Count>0 then begin
    310376      FMErrorForm.Memo.Lines.Assign(Log);
    311377      FMErrorForm.PrepMessage;
    312378      FMErrorForm.ShowModal;
    313     end; 
     379    end;
    314380    Log.Free;
    315381    if (BatchGrid.RowCount=3)and(BatchGrid.Cells[0,2]='') then begin
     
    322388    end else begin
    323389      btnClearGrid.Enabled := true;
    324       btnSaveGrid.Enabled := true; 
     390      btnSaveGrid.Enabled := true;
    325391      btnAbortRegistration.Enabled := false;
    326392    end;
     393    FailedPatients.Free;
     394
    327395  end;
    328396
    329397  function TBatchAddForm.RegisterOne(oneRow : string; Log : TStringList) : string;
    330   var RPCResult : string;
     398  //Returns: NewIEN^Bool1^Bool2^Bool3
     399    //    NewIEN can be a #, or NOT_ADDED
     400    //    For each Bool, 0=false, 1=true
     401    //    Bool1 : Patient previously registered
     402    //    Bool2 : Patient registered this time (using identifier fields)
     403    //    Bool3 : Some Problem occurred during filing
     404  var tempResult,RPCResult : string;
    331405      Msg : string;
    332406      i : integer;
     
    336410    RPCBrokerV.Param[0].Mult['"REQUEST"'] := 'REGISTER PATIENT^'+oneRow;
    337411    RPCBrokerV.Call;
    338     RPCResult := RPCBrokerV.Results[0];    //returns:  error: -1;  success=1
    339     Msg := piece(RPCResult,'^',2);
    340     result := piece(RPCResult,'^',3);
    341     if result = '' then result := NOT_ADDED;
    342     if piece(RPCResult,'^',1)='-1' then begin
    343       if Msg='Patient already registered' then begin
    344         result := ALREADY_ADDED;
    345         exit;
    346       end; 
     412    RPCResult := RPCBrokerV.Results[0];
     413    //returns:  error: -1^Message;  success=1^Success^IEN; or Equivical=0^Message^IEN
     414    //If 0 then Message is in this format
     415    //    [Bool1;Bool2;Bool3;Bool4;Bool5*MessageText]
     416    //    For each Bool, 0=false, 1=true
     417    //    Bool1 : Patient previously registered
     418    //    Bool2 : Patient registered this time (using identifier fields)
     419    //    Bool3 : Problem filing non-identifier fields
     420    //    Bool4 : Problem filing data info sub-file fields
     421    //    Bool5 : Problem filing HRN
     422    tempResult := piece(RPCResult,'^',1);
     423    if tempResult='1' then begin  //1=Success
     424      result := piece(RPCResult,'^',3)+'^0^1^0';
     425    end else if tempResult='0' then begin  //0=Mixed results
     426      Msg := piece(RPCResult,'^',2);
     427      result := piece(RPCResult,'^',3);
     428      if result = '' then result := NOT_ADDED;
     429      result := result + '^' + Piece(Msg,';',1) + '^' + Piece(Msg,';',2);
     430      if Pos('1',Pieces(Msg,';',3,5))>0 then begin
     431        result := result + '^1';
     432        if RPCBrokerV.Results.Count > 1 then begin
     433          Log.Add('-----------------------------------------------');
     434          Log.Add('There was a problem with registering a patient.');
     435          for i := 1 to RPCBrokerV.Results.Count-1 do begin
     436            Log.Add(RPCBrokerV.Results.Strings[i]);
     437          end;
     438        end;
     439      end else begin
     440        result := result + '^0';
     441      end;
     442    end else begin  //should be tempResult='-1'   //-1=Error
    347443      FMErrorForm.Memo.Lines.Assign(RPCBrokerV.Results);
    348444      FMErrorForm.PrepMessage;  //Does some clean up of the message format
     
    350446      Log.Add('-----------------------------------------------');
    351447      Log.Add('There was a problem with registering a patient.');
    352       //Log.Add('This was the data sent to the server: ');
    353       //Log.Add('    '+oneRow);
    354448      for i:= 0 to FMErrorForm.Memo.Lines.Count-1 do begin
    355449        Log.Add(FMErrorForm.Memo.Lines.Strings[i]);
    356       end;   
    357       Log.Add(' ');     
    358       FMErrorForm.Memo.Lines.Clear;     
    359       if Msg='Success (but see message)' then exit;
    360       result := NOT_ADDED;
    361     end;     
    362   end;
    363 
     450      end;
     451      Log.Add(' ');
     452      FMErrorForm.Memo.Lines.Clear;
     453      result := NOT_ADDED+'^0^0^1';  //Not-prev-reg^Not-reg-this-time^Problem-occured
     454    end;
     455  end;
     456
     457  {
    364458  procedure TBatchAddForm.DelGridRow(BatchGrid : TStringGrid; row : integer);
    365459  var col : integer;
     
    374468        end else begin
    375469          BatchGrid.RowCount := BatchGrid.RowCount-1;
    376         end; 
     470        end;
    377471        exit;
    378472      end;
     
    381475      end;
    382476      inc(row);
    383     until (1=0);     
    384   end; 
     477    until (1=0);
     478  end;
     479  }
    385480 
    386481  procedure TBatchAddForm.FormDestroy(Sender: TObject);
     
    395490    List.Add(''); //fill 0'th column will null
    396491    for i := 1 to BatchGrid.ColCount-1 do begin
    397       List.Add(BatchGrid.Cells[i,1]);     
     492      List.Add(BatchGrid.Cells[i,1]);
    398493    end;
    399494  end;
     
    402497  //Output format: FldNum1^Value1^fldNum2^Value2^FldNum3^Value3...
    403498  var i : integer;
    404       oneValue : string;
    405   begin   
     499  begin
    406500    result := '';
    407501    if row >= BatchGrid.RowCount then exit;
     
    410504    end;
    411505  end;
     506
     507  function TBatchAddForm.RowToStr(row : integer) : string;
     508  //Output format: Cell0^Cell1^Cell2^Cell3^Cell4....
     509  var i : integer;
     510  begin
     511    result := '';
     512    if row >= BatchGrid.RowCount then exit;
     513    for i := 0 to BatchGrid.ColCount-1 do begin
     514      result := result + BatchGrid.Cells[i,row]+'^';
     515    end;
     516  end;
     517
     518  procedure TBatchAddForm.AddRowFromStr(Str : string);
     519  var   row : integer;
     520        i : integer;
     521  begin
     522    BatchGrid.RowCount := BatchGrid.RowCount + 1;
     523    row := BatchGrid.RowCount-1;
     524    for i := 0 to BatchGrid.ColCount-1 do begin
     525      BatchGrid.Cells[i,row] := Piece(Str,'^',i+1);
     526    end;
     527  end;
     528
    412529
    413530  procedure TBatchAddForm.btnAbortRegistrationClick(Sender: TObject);
  • cprs/branches/GUI-config/DebugU.dfm

    r493 r542  
    11object DebugForm: TDebugForm
    2   Left = 6
    3   Top = 2
     2  Left = 324
     3  Top = 204
    44  Width = 518
    55  Height = 488
  • cprs/branches/GUI-config/EditTextU.dfm

    r476 r542  
    11object EditTextForm: TEditTextForm
    2   Left = 160
    3   Top = 115
     2  Left = 281
     3  Top = 207
    44  Width = 675
    55  Height = 480
  • cprs/branches/GUI-config/EditTextU.pas

    r476 r542  
    6262implementation
    6363
    64 uses FMErrorU, ORNet, ORFn, Trpcb;
     64uses FMErrorU, ORNet, ORFn,
     65     Trpcb ;  //needed for .ptype types
    6566
    6667{$R *.dfm}
  • cprs/branches/GUI-config/FMErrorU.dfm

    r476 r542  
    11object FMErrorForm: TFMErrorForm
    2   Left = 261
    3   Top = 167
     2  Left = 1217
     3  Top = 320
    44  Width = 482
    55  Height = 417
  • cprs/branches/GUI-config/GUI_Config.cfg

    r493 r542  
    3434-LE"c:\program files\borland\delphi7\Projects\Bpl"
    3535-LN"c:\program files\borland\delphi7\Projects\Bpl"
    36 -U"P:\Vista\GUI-config\CPRS-Lib;P:\Vista\GUI-config\CPRS-Lib\DCU;P:\Vista\GUI-config\SkinStuff;P:\vista\tmg-cprs\BDK32;P:\vista\tmg-cprs\BDK32\Source"
    37 -O"P:\Vista\GUI-config\CPRS-Lib;P:\Vista\GUI-config\CPRS-Lib\DCU;P:\Vista\GUI-config\SkinStuff;P:\vista\tmg-cprs\BDK32;P:\vista\tmg-cprs\BDK32\Source"
    38 -I"P:\Vista\GUI-config\CPRS-Lib;P:\Vista\GUI-config\CPRS-Lib\DCU;P:\Vista\GUI-config\SkinStuff;P:\vista\tmg-cprs\BDK32;P:\vista\tmg-cprs\BDK32\Source"
    39 -R"P:\Vista\GUI-config\CPRS-Lib;P:\Vista\GUI-config\CPRS-Lib\DCU;P:\Vista\GUI-config\SkinStuff;P:\vista\tmg-cprs\BDK32;P:\vista\tmg-cprs\BDK32\Source"
     36-U"P:\Vista\GUI-config\CPRS-Lib\DCU;P:\Vista\GUI-config\CPRS-Lib;P:\Vista\GUI-config\SkinStuff;P:\vista\GUI-config\BDK32;P:\vista\GUI-config\BDK32\Source"
     37-O"P:\Vista\GUI-config\CPRS-Lib\DCU;P:\Vista\GUI-config\CPRS-Lib;P:\Vista\GUI-config\SkinStuff;P:\vista\GUI-config\BDK32;P:\vista\GUI-config\BDK32\Source"
     38-I"P:\Vista\GUI-config\CPRS-Lib\DCU;P:\Vista\GUI-config\CPRS-Lib;P:\Vista\GUI-config\SkinStuff;P:\vista\GUI-config\BDK32;P:\vista\GUI-config\BDK32\Source"
     39-R"P:\Vista\GUI-config\CPRS-Lib\DCU;P:\Vista\GUI-config\CPRS-Lib;P:\Vista\GUI-config\SkinStuff;P:\vista\GUI-config\BDK32;P:\vista\GUI-config\BDK32\Source"
    4040-DUSE_SKINS
    4141-w-UNSAFE_TYPE
  • cprs/branches/GUI-config/GUI_Config.dof

    r493 r542  
    9595PackageDLLOutputDir=
    9696PackageDCPOutputDir=
    97 SearchPath=P:\Vista\GUI-config\CPRS-Lib;P:\Vista\GUI-config\CPRS-Lib\DCU;P:\Vista\GUI-config\SkinStuff;P:\vista\tmg-cprs\BDK32;P:\vista\tmg-cprs\BDK32\Source
     97SearchPath=P:\Vista\GUI-config\CPRS-Lib\DCU;P:\Vista\GUI-config\CPRS-Lib;P:\Vista\GUI-config\SkinStuff;P:\vista\GUI-config\BDK32;P:\vista\GUI-config\BDK32\Source
    9898Packages=vcl;rtl;vclx;indy;inet;xmlrtl;vclie;inetdbbde;inetdbxpress;dbrtl;dsnap;dsnapcon;vcldb;soaprtl;VclSmp;dbexpress;dbxcds;inetdb;bdertl;vcldbx;webdsnap;websnap;adortl;ibxpress;teeui;teedb;tee;dss;visualclx;visualdbclx;vclactnband;vclshlctrls;IntrawebDB_50_70;Intraweb_50_70;Rave50CLX;Rave50VCL;dclaxserver;TntUnicodeVcl_R70;dcldklang7;dklang7;PNGpackage
    9999Conditionals=USE_SKINS
     
    101101UsePackages=0
    102102[Parameters]
    103 RunParams=s=192.168.3.111 p=9230 debug=enable
     103RunParams=
    104104HostApplication=
    105105Launcher=
     
    111111RootDir=C:\Program Files\Borland\Delphi7\Bin\
    112112[Version Info]
    113 IncludeVerInfo=0
     113IncludeVerInfo=1
    114114AutoIncBuild=0
    115115MajorVer=1
    116 MinorVer=0
     116MinorVer=1
    117117Release=0
    118118Build=0
     
    127127CompanyName=
    128128FileDescription=
    129 FileVersion=1.0.0.0
     129FileVersion=1.1.0.0
    130130InternalName=
    131131LegalCopyright=
     
    142142Item0=WinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE;
    143143[HistoryLists\hlSearchPath]
    144 Count=11
    145 Item0=P:\Vista\GUI-config\CPRS-Lib;P:\Vista\GUI-config\CPRS-Lib\DCU;P:\Vista\GUI-config\SkinStuff;P:\vista\tmg-cprs\BDK32;P:\vista\tmg-cprs\BDK32\Source
    146 Item1=P:\Vista\GUI-config\CPRS-Lib;P:\Vista\GUI-config\CPRS-Lib\DCU;P:\Vista\GUI-config\SkinStuff
    147 Item2=P:\Vista\GUI-config\CPRS-Lib;P:\Vista\GUI-config\CPRS-Lib\DCU;P:\Vista\GUI-config\SkinStuff;C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-Lib;C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-Lib\dcu
    148 Item3=C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-Lib;C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-Lib\dcu;P:\Vista\GUI-config\SkinStuff
    149 Item4=C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-Lib;C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-Lib\dcu;C:\Program Files\Borland\Delphi7\Projects\TPNGGraphics;P:\Vista\GUI-config\SkinStuff
    150 Item5=C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-Lib;C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-Lib\dcu;C:\Program Files\Borland\Delphi7\Projects\TPNGGraphics
    151 Item6=C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-Lib;C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-Lib\dcu
    152 Item7=C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-Lib
    153 Item8=..\CPRS-Lib;C:\Program Files\Borland\Delphi7\Projects\TPNGGraphics;C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-1.0.23.15\Broker;C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-1.0.23.15\Broker\Source;C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-1.0.23.15\Broker\D6
    154 Item9=..\CPRS-Lib;C:\Program Files\Borland\Delphi7\Projects\TPNGGraphics
    155 Item10=..\CPRS-Lib
     144Count=13
     145Item0=P:\Vista\GUI-config\CPRS-Lib\DCU;P:\Vista\GUI-config\CPRS-Lib;P:\Vista\GUI-config\SkinStuff;P:\vista\GUI-config\BDK32;P:\vista\GUI-config\BDK32\Source
     146Item1=P:\Vista\GUI-config\CPRS-Lib\DCU;P:\Vista\GUI-config\CPRS-Lib;P:\Vista\GUI-config\SkinStuff;P:\vista\tmg-cprs\BDK32;P:\vista\tmg-cprs\BDK32\Source
     147Item2=P:\Vista\GUI-config\CPRS-Lib;P:\Vista\GUI-config\CPRS-Lib\DCU;P:\Vista\GUI-config\SkinStuff;P:\vista\tmg-cprs\BDK32;P:\vista\tmg-cprs\BDK32\Source
     148Item3=P:\Vista\GUI-config\CPRS-Lib;P:\Vista\GUI-config\CPRS-Lib\DCU;P:\Vista\GUI-config\SkinStuff
     149Item4=P:\Vista\GUI-config\CPRS-Lib;P:\Vista\GUI-config\CPRS-Lib\DCU;P:\Vista\GUI-config\SkinStuff;C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-Lib;C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-Lib\dcu
     150Item5=C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-Lib;C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-Lib\dcu;P:\Vista\GUI-config\SkinStuff
     151Item6=C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-Lib;C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-Lib\dcu;C:\Program Files\Borland\Delphi7\Projects\TPNGGraphics;P:\Vista\GUI-config\SkinStuff
     152Item7=C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-Lib;C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-Lib\dcu;C:\Program Files\Borland\Delphi7\Projects\TPNGGraphics
     153Item8=C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-Lib;C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-Lib\dcu
     154Item9=C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-Lib
     155Item10=..\CPRS-Lib;C:\Program Files\Borland\Delphi7\Projects\TPNGGraphics;C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-1.0.23.15\Broker;C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-1.0.23.15\Broker\Source;C:\Program Files\Borland\Delphi7\Projects\Vista\CPRS-1.0.23.15\Broker\D6
     156Item11=..\CPRS-Lib;C:\Program Files\Borland\Delphi7\Projects\TPNGGraphics
     157Item12=..\CPRS-Lib
    156158[HistoryLists\hlUnitOutputDirectory]
    157159Count=1
  • cprs/branches/GUI-config/GUI_Config.dpr

    r493 r542  
    11program GUI_Config;
    2    (* 
     2   (*
    33   WorldVistA Configuration Utility
    44   (c) 8/2008 Kevin Toppenberg
    5    Programmed by Kevin Toppenberg, Eddie Hagood 
    6    
     5   Programmed by Kevin Toppenberg, Eddie Hagood
     6
    77   Family Physicians of Greeneville, PC
    88   1410 Tusculum Blvd, Suite 2600
    99   Greeneville, TN 37745
    1010   kdtop@yahoo.com
    11                                                  
     11
    1212   This library is free software; you can redistribute it and/or
    1313   modify it under the terms of the GNU Lesser General Public
     
    2323   License along with this library; if not, write to the Free Software
    2424   Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
    25   *)   
     25  *)
    2626
    2727uses
    2828  Forms,
    2929  MainU in 'MainU.pas' {MainForm},
    30   ORFn in '..\CPRS-Lib\ORFn.pas',
    3130  frmSplash in 'frmSplash.pas' {SplashForm},
    3231  LookupU in 'LookupU.pas' {FieldLookupForm},
  • cprs/branches/GUI-config/GUI_Config.dsk

    r493 r542  
    11[Closed Files]
    2 File_0=SourceModule,'P:\vista\tmg-cprs\BDK32\Source\wsockc.pas',0,1,1464,17,1475,0,0
    3 File_1=SourceModule,'P:\Vista\GUI-config\MainU.dfm',0,1,1,1,1,0,0
    4 File_2=SourceModule,'P:\vista\GUI-config\SkinFormU.pas',0,1,1,1,1,1,1
    5 File_3=SourceModule,'P:\Vista\GUI-config\LookupU.dfm',0,1,1,1,1,0,0
    6 File_4=SourceModule,'P:\vista\tmg-cprs\BDK32\Source\VERGENCECONTEXTORLib_TLB.pas',0,1,124,29,11,0,0
    7 File_5=SourceModule,'C:\Program Files\VISTA\BDK32_is_this_old\Source\Trpcb.pas',0,1,43,1,53,0,0
    8 File_6=SourceModule,'P:\vista\GUI-config\CPRS-Lib\ORNet.pas',0,1,188,21,195,0,0
    9 File_7=SourceModule,'C:\PROGRA~1\VISTA\BDK32\Source\VERGENCECONTEXTORLib_TLB.pas',0,1,1109,31,1120,0,0
    10 File_8=SourceModule,'c:\program files\borland\delphi7\source\vcl\OleCtrls.pas',0,1,86,12,92,0,0
    11 File_9=SourceModule,'c:\program files\borland\delphi7\source\rtl\Win\ShellAPI.pas',0,1,1,1,1,0,0
     2File_0=SourceModule,'P:\vista\GUI-config\BDK32\Source\TRPCB.pas',0,1,1045,1,1059,0,0
     3File_1=SourceModule,'P:\vista\GUI-config\CreateTemplateU.pas',0,1,140,11,145,0,0
     4File_2=SourceModule,'P:\vista\GUI-config\SetSelU.pas',0,1,1,1,1,1,0
     5File_3=SourceModule,'P:\vista\GUI-config\SubfilesU.pas',0,1,102,14,113,0,0
     6File_4=SourceModule,'P:\vista\GUI-config\FMErrorU.pas',0,1,1,71,43,1,0
     7File_5=SourceModule,'P:\vista\GUI-config\LookupU.pas',0,1,1,21,3,1,1
     8File_6=SourceModule,'P:\vista\GUI-config\PostU.pas',0,1,70,1,1,1,0
     9File_7=SourceModule,'P:\vista\GUI-config\BatchAddU.pas',0,1,459,3,480,0,0
    1210
    1311[Modules]
    14 Module0=P:\vista\GUI-config\GUI_Config.dpr
    15 Module1=P:\Vista\GUI-config\MainU.pas
    16 Module2=P:\vista\GUI-config\DebugU.pas
    17 Module3=P:\Vista\GUI-config\CPRS-Lib\ORCtrls.pas
    18 Module4=P:\Vista\GUI-config\SubfilesU.pas
    19 Module5=P:\Vista\GUI-config\CPRS-Lib\ORFn.pas
    20 Module6=P:\Vista\GUI-config\BatchAddU.pas
    21 Module7=P:\Vista\GUI-config\frmSplash.pas
    22 Module8=P:\vista\GUI-config\SkinFormU.dfm
    23 Module9=P:\vista\GUI-config\CreateTemplateU.pas
    24 Module10=P:\vista\GUI-config\EditTextU.pas
    25 Module11=P:\vista\GUI-config\PostU.pas
    26 Module12=P:\vista\GUI-config\SetSelU.pas
    27 Module13=P:\Vista\GUI-config\LookupU.pas
    28 Count=14
     12Module0=P:\vista\GUI-config\MainU.pas
     13Module1=P:\vista\GUI-config\frmSplash.pas
     14Module2=P:\vista\GUI-config\AboutU.pas
     15Module3=P:\Vista\GUI-config\CPRS-Lib\ORNet.pas
     16Module4=P:\vista\GUI-config\SkinFormU.pas
     17Module5=P:\vista\GUI-config\BDK32\Source\wsockc.pas
     18Module6=P:\vista\GUI-config\GUI_Config.dpr
     19Count=7
    2920EditWindowCount=1
    3021
     22[P:\vista\GUI-config\MainU.pas]
     23ModuleType=SourceModule
     24FormState=1
     25FormOnTop=0
     26
     27[P:\vista\GUI-config\frmSplash.pas]
     28ModuleType=SourceModule
     29FormState=1
     30FormOnTop=1
     31
     32[P:\vista\GUI-config\AboutU.pas]
     33ModuleType=SourceModule
     34FormState=1
     35FormOnTop=0
     36
     37[P:\Vista\GUI-config\CPRS-Lib\ORNet.pas]
     38ModuleType=SourceModule
     39FormState=0
     40FormOnTop=0
     41
     42[P:\vista\GUI-config\SkinFormU.pas]
     43ModuleType=SourceModule
     44FormState=0
     45FormOnTop=0
     46
     47[P:\vista\GUI-config\BDK32\Source\wsockc.pas]
     48ModuleType=SourceModule
     49FormState=0
     50FormOnTop=0
     51
    3152[P:\vista\GUI-config\GUI_Config.dpr]
    32 ModuleType=SourceModule
    33 FormState=0
    34 FormOnTop=0
    35 
    36 [P:\Vista\GUI-config\MainU.pas]
    37 ModuleType=SourceModule
    38 FormState=1
    39 FormOnTop=0
    40 
    41 [P:\vista\GUI-config\DebugU.pas]
    42 ModuleType=SourceModule
    43 FormState=1
    44 FormOnTop=0
    45 
    46 [P:\Vista\GUI-config\CPRS-Lib\ORCtrls.pas]
    47 ModuleType=SourceModule
    48 FormState=0
    49 FormOnTop=0
    50 
    51 [P:\Vista\GUI-config\SubfilesU.pas]
    52 ModuleType=SourceModule
    53 FormState=1
    54 FormOnTop=0
    55 
    56 [P:\Vista\GUI-config\CPRS-Lib\ORFn.pas]
    57 ModuleType=SourceModule
    58 FormState=0
    59 FormOnTop=0
    60 
    61 [P:\Vista\GUI-config\BatchAddU.pas]
    62 ModuleType=SourceModule
    63 FormState=1
    64 FormOnTop=0
    65 
    66 [P:\Vista\GUI-config\frmSplash.pas]
    67 ModuleType=SourceModule
    68 FormState=0
    69 FormOnTop=0
    70 
    71 [P:\vista\GUI-config\SkinFormU.dfm]
    72 ModuleType=SourceModule
    73 FormState=0
    74 FormOnTop=0
    75 
    76 [P:\vista\GUI-config\CreateTemplateU.pas]
    77 ModuleType=SourceModule
    78 FormState=0
    79 FormOnTop=0
    80 
    81 [P:\vista\GUI-config\EditTextU.pas]
    82 ModuleType=SourceModule
    83 FormState=0
    84 FormOnTop=0
    85 
    86 [P:\vista\GUI-config\PostU.pas]
    87 ModuleType=SourceModule
    88 FormState=0
    89 FormOnTop=0
    90 
    91 [P:\vista\GUI-config\SetSelU.pas]
    92 ModuleType=SourceModule
    93 FormState=0
    94 FormOnTop=0
    95 
    96 [P:\Vista\GUI-config\LookupU.pas]
    9753ModuleType=SourceModule
    9854FormState=0
     
    10460
    10561[EditWindow0]
    106 ViewCount=14
    107 CurrentView=11
     62ViewCount=7
     63CurrentView=3
    10864View0=0
    10965View1=1
     
    11369View5=5
    11470View6=6
    115 View7=7
    116 View8=8
    117 View9=9
    118 View10=10
    119 View11=11
    120 View12=12
    121 View13=13
    12271CodeExplorer=CodeExplorer@EditWindow0
    12372MessageView=MessageView@EditWindow0
     
    12574Visible=1
    12675State=0
    127 Left=240
    128 Top=118
    129 Width=776
    130 Height=614
     76Left=22
     77Top=121
     78Width=927
     79Height=648
    13180MaxLeft=-4
    132 MaxTop=109
    133 ClientWidth=768
    134 ClientHeight=580
    135 LeftPanelSize=0
     81MaxTop=104
     82ClientWidth=919
     83ClientHeight=614
     84LeftPanelSize=140
    13685LeftPanelClients=CodeExplorer@EditWindow0
    137 LeftPanelData=00000400010000000C000000436F64654578706C6F726572C600000000000000027F01000000000000010000000000000000000000000100000000C600000000000000FFFFFFFF
     86LeftPanelData=000004000000000000000000000000000000000000000000000100000000000000000C000000436F64654578706C6F726572FFFFFFFF
    13887RightPanelSize=0
    139 BottomPanelSize=0
    140 BottomPanelClients=WatchWindow,MessageView@EditWindow0
    141 BottomPanelData=00000400020000000B000000576174636857696E646F770B0000004D65737361676556696577000300000000000002CD0000000000000001000000008B010000000000000100000001580300000000000002000000006C000000000000000200000002BE0000000000000003000000000000000000000000030000000000000000000000000300000000AC0100000000000003000000005803000000000000030000000058030000000000000300000000580300000000000003000000005803000000000000030000000058030000000000000200000000D80000000000000001000000005803000000000000010000000058030000000000000100000000AC0100000000000001000000005803000000000000010000000058030000000000000100000000AC010000000000000100000000C401000000000000010000000066000000000000000100000000D7020000000000000100000000160300000000000001000000001603000000000000010000000016030000000000000100000000160300000000000001000000008B0100000000000001000000008B0100000000000001000000008B010000000000000100000000F8020000000000000100000000FD02000000000000010000000016030000000000000100000000160300000000000001000000007E01000000000000010000000100030000000000000200000000CD0000000B0000004D657373616765566965770200000000CD0000000000000001000000000003000000000000FFFFFFFF
     88BottomPanelSize=85
     89BottomPanelClients=MessageView@EditWindow0
     90BottomPanelData=00000400000000009703000000000000025500000000000000010000000000000000000000000100000000AE020000000000000100000000970300000B0000004D65737361676556696577FFFFFFFF
    14291
    14392[View0]
    144 Module=P:\Vista\GUI-config\MainU.pas
     93Module=P:\vista\GUI-config\GUI_Config.dpr
    14594CursorX=1
    146 CursorY=297
    147 TopLine=281
     95CursorY=66
     96TopLine=58
    14897LeftCol=1
    14998
    15099[View1]
    151 Module=P:\Vista\GUI-config\CPRS-Lib\ORCtrls.pas
    152 CursorX=22
    153 CursorY=343
    154 TopLine=336
    155 LeftCol=1
    156 
    157 [View2]
    158 Module=P:\vista\GUI-config\DebugU.pas
    159 CursorX=28
    160 CursorY=4
    161 TopLine=1
    162 LeftCol=1
    163 
    164 [View3]
    165 Module=P:\Vista\GUI-config\LookupU.pas
     100Module=P:\vista\GUI-config\frmSplash.pas
    166101CursorX=1
    167102CursorY=1
     
    169104LeftCol=1
    170105
     106[View2]
     107Module=P:\vista\GUI-config\AboutU.pas
     108CursorX=1
     109CursorY=108
     110TopLine=107
     111LeftCol=1
     112
     113[View3]
     114Module=P:\vista\GUI-config\MainU.pas
     115CursorX=1
     116CursorY=1498
     117TopLine=1481
     118LeftCol=1
     119
    171120[View4]
    172 Module=P:\Vista\GUI-config\CPRS-Lib\ORFn.pas
    173 CursorX=38
    174 CursorY=41
    175 TopLine=1
     121Module=P:\vista\GUI-config\BDK32\Source\wsockc.pas
     122CursorX=1
     123CursorY=1479
     124TopLine=1471
    176125LeftCol=1
    177126
    178127[View5]
    179 Module=P:\Vista\GUI-config\SubfilesU.pas
    180 CursorX=9
    181 CursorY=97
    182 TopLine=89
     128Module=P:\vista\GUI-config\SkinFormU.pas
     129CursorX=24
     130CursorY=124
     131TopLine=113
    183132LeftCol=1
    184133
    185134[View6]
    186 Module=P:\vista\GUI-config\SetSelU.pas
    187 CursorX=9
    188 CursorY=32
    189 TopLine=24
    190 LeftCol=1
    191 
    192 [View7]
    193 Module=P:\vista\GUI-config\PostU.pas
    194 CursorX=9
    195 CursorY=42
    196 TopLine=34
    197 LeftCol=1
    198 
    199 [View8]
    200 Module=P:\vista\GUI-config\EditTextU.pas
    201 CursorX=22
    202 CursorY=64
    203 TopLine=56
    204 LeftCol=1
    205 
    206 [View9]
    207 Module=P:\vista\GUI-config\CreateTemplateU.pas
    208 CursorX=22
    209 CursorY=87
    210 TopLine=79
    211 LeftCol=1
    212 
    213 [View10]
    214 Module=P:\vista\GUI-config\SkinFormU.dfm
     135Module=P:\Vista\GUI-config\CPRS-Lib\ORNet.pas
    215136CursorX=1
    216 CursorY=1
    217 TopLine=1
    218 LeftCol=1
    219 
    220 [View11]
    221 Module=P:\vista\GUI-config\GUI_Config.dpr
    222 CursorX=1
    223 CursorY=67
    224 TopLine=59
    225 LeftCol=1
    226 
    227 [View12]
    228 Module=P:\Vista\GUI-config\frmSplash.pas
    229 CursorX=20
    230 CursorY=32
    231 TopLine=24
    232 LeftCol=1
    233 
    234 [View13]
    235 Module=P:\Vista\GUI-config\BatchAddU.pas
    236 CursorX=30
    237 CursorY=83
    238 TopLine=74
     137CursorY=330
     138TopLine=358
    239139LeftCol=1
    240140
     
    252152Visible=0
    253153State=0
    254 Left=12
    255 Top=102
    256 Width=756
    257 Height=103
     154Left=0
     155Top=0
     156Width=764
     157Height=129
    258158MaxLeft=-1
    259159MaxTop=-1
     
    265165
    266166[Breakpoints]
    267 Count=1
    268 Breakpoint0='P:\Vista\GUI-config\MainU.pas',295,'',0,1,'',1,0,0,'',1,'','',''
     167Count=2
     168Breakpoint0='P:\vista\GUI-config\MainU.pas',990,'',0,1,'',1,0,0,'',1,'','',''
     169Breakpoint1='P:\vista\GUI-config\MainU.pas',1878,'',0,1,'',1,0,0,'',1,'','',''
    269170
    270171[AddressBreakpoints]
     
    274175Create=1
    275176Visible=1
    276 State=0
    277 Left=6
    278 Top=2
    279 Width=1013
     177State=2
     178Left=0
     179Top=0
     180Width=1024
    280181Height=112
    281182MaxLeft=-1
    282183MaxTop=-1
    283 ClientWidth=1005
     184MaxWidth=1032
     185MaxHeight=112
     186ClientWidth=1024
    284187ClientHeight=78
    285188
    286189[ProjectManager]
    287190Create=1
    288 Visible=1
    289 State=0
    290 Left=172
    291 Top=159
    292 Width=689
    293 Height=561
    294 MaxLeft=-1
    295 MaxTop=-1
    296 ClientWidth=681
    297 ClientHeight=535
     191Visible=0
     192State=0
     193Left=403
     194Top=294
     195Width=429
     196Height=383
     197MaxLeft=-1
     198MaxTop=-1
     199ClientWidth=421
     200ClientHeight=357
    298201TBDockHeight=408
    299202LRDockWidth=623
     
    321224State=0
    322225Left=0
    323 Top=28
     226Top=0
    324227Width=800
    325228Height=561
     
    352255Left=0
    353256Top=0
    354 Width=214
    355 Height=559
    356 MaxLeft=-1
    357 MaxTop=-1
    358 ClientWidth=214
    359 ClientHeight=559
     257Width=206
     258Height=411
     259MaxLeft=-1
     260MaxTop=-1
     261ClientWidth=206
     262ClientHeight=411
    360263TBDockHeight=527
    361264LRDockWidth=250
    362265Dockable=1
    363 SplitPos=114
     266SplitPos=73
    364267ArrangeBy=Name
    365 SelectedItem=Visible
    366 ExpandedItems=Anchors,Options
     268SelectedItem=Caption
     269ExpandedItems=Anchors,Menu,Options
    367270HiddenCategories=Legacy
    368271
     
    393296Visible=0
    394297State=0
    395 Left=60
    396 Top=412
    397 Width=874
     298Left=0
     299Top=0
     300Width=1024
    398301Height=210
    399302MaxLeft=-1
    400303MaxTop=-1
    401 ClientWidth=866
     304ClientWidth=1016
    402305ClientHeight=184
    403306TBDockHeight=355
     
    431334Left=0
    432335Top=0
    433 Width=214
    434 Height=559
    435 MaxLeft=-1
    436 MaxTop=-1
    437 ClientWidth=214
    438 ClientHeight=559
     336Width=206
     337Height=411
     338MaxLeft=-1
     339MaxTop=-1
     340ClientWidth=206
     341ClientHeight=411
    439342TBDockHeight=527
    440343LRDockWidth=250
     
    551454[CodeExplorer@EditWindow0]
    552455Create=1
    553 Visible=0
     456Visible=1
    554457State=0
    555458Left=0
    556459Top=12
    557 Width=198
    558 Height=371
    559 MaxLeft=-1
    560 MaxTop=-1
    561 ClientWidth=198
    562 ClientHeight=371
    563 TBDockHeight=371
    564 LRDockWidth=198
     460Width=140
     461Height=514
     462MaxLeft=-1
     463MaxTop=-1
     464ClientWidth=140
     465ClientHeight=514
     466TBDockHeight=305
     467LRDockWidth=140
    565468Dockable=1
    566469
    567470[MessageView@EditWindow0]
    568471Create=1
    569 Visible=0
     472Visible=1
    570473State=0
    571474Left=12
    572475Top=0
    573 Width=756
    574 Height=205
    575 MaxLeft=-1
    576 MaxTop=-1
    577 ClientWidth=756
    578 ClientHeight=205
    579 TBDockHeight=205
     476Width=907
     477Height=85
     478MaxLeft=-1
     479MaxTop=-1
     480ClientWidth=907
     481ClientHeight=85
     482TBDockHeight=85
    580483LRDockWidth=443
    581484Dockable=1
     
    589492Visible=1
    590493State=0
    591 Left=6
    592 Top=118
    593 Width=230
    594 Height=614
    595 MaxLeft=-1
    596 MaxTop=-1
    597 ClientWidth=222
    598 ClientHeight=588
     494Left=3
     495Top=152
     496Width=222
     497Height=466
     498MaxLeft=-1
     499MaxTop=-1
     500ClientWidth=214
     501ClientHeight=440
    599502TBDockHeight=539
    600503LRDockWidth=258
  • cprs/branches/GUI-config/GUI_Config.ini

    r482 r542  
    22Default Skin=SkinStuff\Skins\Mac ICQ.ipz
    33Load At Startup=1
     4[Settings]
     5UCaseOnly=1
     6
  • cprs/branches/GUI-config/LookupU.dfm

    r476 r542  
    11object FieldLookupForm: TFieldLookupForm
    2   Left = 435
    3   Top = 120
     2  Left = 1217
     3  Top = 365
    44  Width = 302
    55  Height = 169
     
    4545    OnDblClick = ORComboBoxDblClick
    4646    OnNeedData = ORComboBoxNeedData
     47    CharsNeedMatch = 1
    4748  end
    4849  object OKBtn: TBitBtn
  • cprs/branches/GUI-config/LookupU.pas

    r493 r542  
    4848    //procedure InitORComboBox(ORComboBox: TORComboBox; initValue : string);
    4949    procedure PrepForm(FileNum,InitValue : string);
    50     function SubSetOfFile(FileNum: string; const StartFrom: string; 
     50    function SubSetOfFile(FileNum: string; const StartFrom: string;
    5151                          Direction: Integer): TStrings;
    5252  end;
     
    5858
    5959uses
    60 ORNet, ORFn, Trpcb, QControls, MainU;
     60ORNet, ORFn,
     61Trpcb,   //needed for .ptype types
     62QControls, MainU;
    6163{$R *.dfm}
    6264
    6365  procedure TFieldLookupForm.ORComboBoxNeedData(Sender: TObject;
    64                                                 const StartFrom: String; 
     66                                                const StartFrom: String;
    6567                                                Direction, InsertAt: Integer);
    6668  var
    67     Result : TStrings;                                               
     69    Result : TStrings;
    6870  begin
    6971    Result := SubSetOfFile(FFileNum, StartFrom, Direction);
  • cprs/branches/GUI-config/MainU.dfm

    r493 r542  
    11object MainForm: TMainForm
    2   Left = 246
    3   Top = 131
    4   Width = 672
    5   Height = 551
     2  Left = 63
     3  Top = 33
     4  Width = 861
     5  Height = 706
    66  Caption = 'WorldVistA Configuration Utility'
    77  Color = 14405057
     
    4646    Left = 0
    4747    Top = 0
    48     Width = 664
    49     Height = 497
    50     ActivePage = tsAdvanced
     48    Width = 853
     49    Height = 652
     50    ActivePage = tsPatients
    5151    Align = alClient
    5252    OwnerDraw = True
     
    6060        Left = 177
    6161        Top = 0
    62         Height = 469
     62        Height = 624
    6363        ResizeStyle = rsUpdate
    6464      end
     
    6767        Top = 0
    6868        Width = 177
    69         Height = 469
     69        Height = 624
    7070        Align = alLeft
    7171        BevelOuter = bvNone
     
    7676          Top = 0
    7777          Width = 177
    78           Height = 434
     78          Height = 589
    7979          Hint = 'Select User to Edit'
    8080          Align = alClient
     
    9898        object Panel5: TPanel
    9999          Left = 0
    100           Top = 434
     100          Top = 589
    101101          Width = 177
    102102          Height = 35
     
    198198        Left = 180
    199199        Top = 0
    200         Width = 476
    201         Height = 469
     200        Width = 665
     201        Height = 624
    202202        Align = alClient
    203203        BevelOuter = bvNone
     
    207207          Left = 0
    208208          Top = 0
    209           Width = 476
    210           Height = 438
     209          Width = 665
     210          Height = 593
    211211          ActivePage = tsBasicPage
    212212          Align = alClient
     
    269269        object ButtonPanel: TPanel
    270270          Left = 0
    271           Top = 438
    272           Width = 476
     271          Top = 593
     272          Width = 665
    273273          Height = 31
    274274          Align = alBottom
     
    277277          TabOrder = 1
    278278          DesignSize = (
    279             476
     279            665
    280280            31)
    281281          object btnUsersApply: TBitBtn
    282             Left = 395
     282            Left = 584
    283283            Top = 3
    284284            Width = 75
     
    317317          end
    318318          object btnUsersRevert: TBitBtn
    319             Left = 311
     319            Left = 500
    320320            Top = 4
    321321            Width = 75
     
    362362        Left = 0
    363363        Top = 0
    364         Width = 656
    365         Height = 469
     364        Width = 845
     365        Height = 624
    366366        Align = alClient
    367367        BevelOuter = bvNone
     
    371371          Left = 177
    372372          Top = 0
    373           Height = 469
     373          Height = 624
    374374          ResizeStyle = rsUpdate
    375375        end
     
    377377          Left = 180
    378378          Top = 0
    379           Width = 476
    380           Height = 469
     379          Width = 665
     380          Height = 624
    381381          Align = alClient
    382382          BevelOuter = bvNone
     
    386386            Left = 0
    387387            Top = 0
    388             Width = 476
    389             Height = 438
     388            Width = 665
     389            Height = 593
    390390            ActivePage = tsBasicSettings
    391391            Align = alClient
     
    448448          object Panel3: TPanel
    449449            Left = 0
    450             Top = 438
    451             Width = 476
     450            Top = 593
     451            Width = 665
    452452            Height = 31
    453453            Align = alBottom
     
    456456            TabOrder = 1
    457457            DesignSize = (
    458               476
     458              665
    459459              31)
    460460            object btnSettingsApply: TBitBtn
    461               Left = 395
     461              Left = 584
    462462              Top = 3
    463463              Width = 75
     
    496496            end
    497497            object btnSettingsRevert: TBitBtn
    498               Left = 311
     498              Left = 500
    499499              Top = 4
    500500              Width = 75
     
    538538          Top = 0
    539539          Width = 177
    540           Height = 469
     540          Height = 624
    541541          Align = alLeft
    542542          BevelOuter = bvNone
     
    547547            Top = 0
    548548            Width = 177
    549             Height = 434
     549            Height = 589
    550550            Hint = 'Select User to Edit'
    551551            Align = alClient
     
    569569          object Panel6: TPanel
    570570            Left = 0
    571             Top = 434
     571            Top = 589
    572572            Width = 177
    573573            Height = 35
     
    586586        Left = 0
    587587        Top = 0
    588         Width = 656
    589         Height = 469
     588        Width = 845
     589        Height = 624
    590590        Align = alClient
    591591        BevelOuter = bvNone
     
    595595          Left = 177
    596596          Top = 0
    597           Height = 469
     597          Height = 624
    598598          ResizeStyle = rsUpdate
    599599        end
     
    601601          Left = 180
    602602          Top = 0
    603           Width = 476
    604           Height = 469
     603          Width = 665
     604          Height = 624
    605605          Align = alClient
    606606          BevelOuter = bvNone
     
    610610            Left = 0
    611611            Top = 0
    612             Width = 476
    613             Height = 438
    614             ActivePage = tsBasicPatients
     612            Width = 665
     613            Height = 593
     614            ActivePage = tsAdvancedPatients
    615615            Align = alClient
    616616            OwnerDraw = True
     
    650650                Left = 0
    651651                Top = 0
    652                 Width = 468
    653                 Height = 410
     652                Width = 657
     653                Height = 565
    654654                Cursor = crHandPoint
    655655                Hint = 'Edit User Fields Here'
     
    673673          object Panel9: TPanel
    674674            Left = 0
    675             Top = 438
    676             Width = 476
     675            Top = 593
     676            Width = 665
    677677            Height = 31
    678678            Align = alBottom
     
    681681            TabOrder = 1
    682682            DesignSize = (
    683               476
     683              665
    684684              31)
    685685            object btnPatientApply: TBitBtn
    686               Left = 395
     686              Left = 584
    687687              Top = 3
    688688              Width = 75
     
    721721            end
    722722            object btnPatientRevert: TBitBtn
    723               Left = 311
     723              Left = 500
    724724              Top = 4
    725725              Width = 75
     
    763763          Top = 0
    764764          Width = 177
    765           Height = 469
     765          Height = 624
    766766          Align = alLeft
    767767          BevelOuter = bvNone
     
    770770          object Panel11: TPanel
    771771            Left = 0
    772             Top = 434
     772            Top = 589
    773773            Width = 177
    774774            Height = 35
     
    868868            Top = 0
    869869            Width = 177
    870             Height = 434
     870            Height = 589
    871871            Style = orcsSimple
    872872            Align = alClient
     
    901901        Left = 0
    902902        Top = 0
    903         Width = 656
    904         Height = 469
     903        Width = 845
     904        Height = 624
    905905        Align = alClient
    906906        BevelOuter = bvNone
     
    910910          Left = 177
    911911          Top = 0
    912           Height = 469
     912          Height = 624
    913913          ResizeStyle = rsUpdate
    914914        end
     
    916916          Left = 180
    917917          Top = 0
    918           Width = 476
    919           Height = 469
     918          Width = 665
     919          Height = 624
    920920          Align = alClient
    921921          BevelOuter = bvNone
     
    925925            Left = 0
    926926            Top = 0
    927             Width = 476
    928             Height = 438
     927            Width = 665
     928            Height = 593
    929929            ActivePage = TabSheet2
    930930            Align = alClient
     
    964964          object Panel14: TPanel
    965965            Left = 0
    966             Top = 438
    967             Width = 476
     966            Top = 593
     967            Width = 665
    968968            Height = 31
    969969            Align = alBottom
     
    971971            TabOrder = 1
    972972            DesignSize = (
    973               476
     973              665
    974974              31)
    975975            object btnAdvancedApply: TBitBtn
    976               Left = 395
     976              Left = 584
    977977              Top = 3
    978978              Width = 75
     
    10111011            end
    10121012            object btnAdvancedRevert: TBitBtn
    1013               Left = 311
     1013              Left = 500
    10141014              Top = 4
    10151015              Width = 75
     
    10531053          Top = 0
    10541054          Width = 177
    1055           Height = 469
     1055          Height = 624
    10561056          Align = alLeft
    10571057          BevelOuter = bvNone
     
    10601060          object BotLeftAdvBtnPanel: TPanel
    10611061            Left = 0
    1062             Top = 434
     1062            Top = 589
    10631063            Width = 177
    10641064            Height = 35
     
    11121112            Top = 0
    11131113            Width = 177
    1114             Height = 434
     1114            Height = 589
    11151115            Align = alClient
    11161116            BevelOuter = bvNone
     
    11811181              Top = 204
    11821182              Width = 177
    1183               Height = 230
     1183              Height = 385
    11841184              Align = alClient
    11851185              BevelOuter = bvNone
     
    12051205                Top = 13
    12061206                Width = 177
    1207                 Height = 217
     1207                Height = 372
    12081208                Style = orcsSimple
    12091209                Align = alClient
  • cprs/branches/GUI-config/MainU.pas

    r493 r542  
    55   (c) 8/2008 Kevin Toppenberg
    66   Programmed by Kevin Toppenberg, Eddie Hagood 
    7    
     7
    88   Family Physicians of Greeneville, PC
    99   1410 Tusculum Blvd, Suite 2600
     
    3636  ipSkinManager,
    3737  {$ENDIF}
    38   Trpcb,
     38  Trpcb, //needed for .ptype types
    3939  ValEdit;
    4040
     
    201201    RPCBrokerParams : TTreeNode;
    202202    Devices : TTreeNode;
    203     FLastSelectedRow,FLastSelectedCol : integer;                 
     203    FLastSelectedRow,FLastSelectedCol : integer;
    204204    FLoadingGrid: boolean;
    205205    DataForGrid : TStringList;   // doesn't own TGridInfo objects
     
    208208    CachedWPField : TStringList;
    209209    FVisibleGridIdx : integer;
     210    FINIFileName : string;  // 8-12-09   elh
    210211    procedure ShowDebugClick(Sender: TObject);
    211212    function FindParam(Param : string) : string;
     
    282283
    283284uses
    284   frmSplash, {Trpcb,}  LookupU, SubfilesU, SetSelU, SelDateTimeU, PostU,
     285  frmSplash, LookupU, SubfilesU, SetSelU, SelDateTimeU, PostU,
    285286  FMErrorU, AboutU, PleaseWaitU, EditTextU, CreateTemplateU, SkinFormU,
    286   BatchAddU, DebugU;
     287  BatchAddU, DebugU,
     288  inifiles;  //8-12-09  elh
    287289
    288290{$R *.dfm}
     
    343345    if not ORNet.ConnectToServer(RPC_CONTEXT) then begin
    344346      DebugForm.Memo.Lines.Add('Failed connection.  Closing.');
     347      messagedlg('Login Failed.',mtError,[mbOK],0);
    345348      Close;
    346349      Exit;
     
    11671170        Inc(GridRow);
    11681171      end;
    1169     end; 
     1172    end;
    11701173    FLoadingGrid := false;
    11711174  end;
     
    11741177  procedure TMainForm.GridSelectCell(Sender: TObject; ACol, ARow: Integer;
    11751178                                     var CanSelect: Boolean);
    1176     (* 
     1179    (*
    11771180    For Field def, here is the legend
    11781181    character     meaning
    1179    
     1182
    11801183    BC            The data is Boolean Computed (true or false).
    11811184    C             The data is Computed.
     
    11871190    Pn            The data is a Pointer reference to file "n".
    11881191    S             The data is from a discrete Set of codes.
    1189    
    1190     N             The data is Numeric-valued.   
    1191    
     1192
     1193    N             The data is Numeric-valued.
     1194
    11921195    Jn            To specify a print length of n characters.
    11931196    Jn,d                To specify printing n characters with decimals.
    1194    
     1197
    11951198    V             The data is a Variable pointer.
    11961199    W             The data is Word processing.
    11971200    WL            The Word processing data is normally printed in Line mode (i.e., without word wrap).
    11981201      *)
    1199   var oneEntry,FieldDef : string;                                     
     1202  var oneEntry,FieldDef : string;
    12001203      date,time: string;
    12011204      FileNum,FieldNum,SubFileNum : string;
     
    12421245          IEN := RecordORComboBox.ItemID;  //get info from selected record
    12431246          if IEN > 0 then IENS := InttoStr(IEN) + ',';
    1244         end; 
     1247        end;
    12451248        if IENS <> '' then begin
    12461249          SubFileForm := TSubFileForm.Create(self);
     
    12501253        end else begin
    12511254          MessageDlg('IENS for File="".  Can''t process.',mtInformation,[MBOK],0);
    1252         end; 
     1255        end;
    12531256      end; 
    12541257    end else if Pos('C',FieldDef)>0 then begin  //computed fields.
     
    12681271        Grid.Cells[ACol,ARow] := date;
    12691272      end;
    1270       CanSelect := true;   
     1273      CanSelect := true;
    12711274    end else if Pos('S',FieldDef)>0 then begin  //Set of Codes
    12721275      SetSelForm.PrepForm(Piece(oneEntry,'^',7));
     
    12841287        Grid.Cells[ACol,ARow] := FieldLookupForm.ORComboBox.Text;
    12851288        CanSelect := true;
    1286       end;     
     1289      end;
    12871290    end;
    12881291    if CanSelect then begin
     
    12901293      FLastSelectedCol := ACol;
    12911294    end;
    1292     GridInfo.ApplyBtn.Enabled := true;   
    1293     GridInfo.RevertBtn.Enabled := true;   
    1294   end;
    1295 
    1296  
     1295    GridInfo.ApplyBtn.Enabled := true;
     1296    GridInfo.RevertBtn.Enabled := true;
     1297  end;
     1298
     1299
    12971300  function TMainForm.GetLineInfo(Grid : TStringGrid; CurrentUserData : TStringList; ARow: integer) : tFileEntry;
    12981301  var fieldNum : string;
     
    13021305  begin
    13031306    fieldNum := Grid.Cells[0,ARow];
    1304     gridRow := FindInStrings(fieldNum, CurrentUserData, fileNum);   
     1307    gridRow := FindInStrings(fieldNum, CurrentUserData, fileNum);
    13051308    if gridRow > -1 then begin
    13061309      oneEntry := CurrentUserData.Strings[gridRow];
     
    13101313      Result.IENS := Piece(oneEntry,'^',2);
    13111314      Result.oldValue := Piece(oneEntry,'^',4);
    1312       Result.newValue := Grid.Cells[2,ARow];     
     1315      Result.newValue := Grid.Cells[2,ARow];
    13131316    end else begin
    13141317      Result.Field := '';
     
    13471350      break;
    13481351    end;
    1349   end; 
    1350  
    1351  
     1352  end;
     1353
     1354
    13521355  function TMainForm.IsSubFile(FieldDef: string ; var SubFileNum : string) : boolean;
    13531356  //SubFileNum is OUT parameter
     
    14551458    FVisibleGridIdx := GetInfoIndexForGrid(Grid);
    14561459  end;
    1457  
    1458  
     1460
     1461
    14591462  procedure TMainForm.CompileChanges(Grid : TStringGrid; CurrentUserData,Changes : TStringList);
    14601463  //Output format:
     
    14641467      Entry : tFileEntry;
    14651468      oneEntry : string;
    1466   begin
     1469      iniFile : TIniFile; // 8-12-09   elh
     1470      UCaseOnly : boolean;
     1471  begin
     1472    FINIFileName := ExtractFilePath(ParamStr(0)) + 'GUI_Config.ini';
     1473    iniFile := TIniFile.Create(FINIFileName);            //8-12-09  elh
     1474    UCaseOnly := inifile.ReadBool('Settings','UCaseOnly',true);
     1475    iniFile.Free;
    14671476    for row := 1 to Grid.RowCount-1 do begin
    14681477      Entry := GetLineInfo(Grid,CurrentUserData, row);
    1469       if Entry.oldValue <> Entry.newValue then begin
    1470         if (Entry.newValue <> CLICK_FOR_SUBS) and
    1471           (Entry.newValue <> COMPUTED_FIELD) and
    1472           (Entry.newValue <> CLICK_TO_EDIT) then begin   
    1473           oneEntry := Entry.FileNum + '^' + Entry.IENS + '^' + Entry.Field + '^' + Entry.FieldName;
    1474           oneEntry := oneEntry + '^' + Entry.newValue + '^' + Entry.oldValue;
    1475           Changes.Add(oneEntry);
    1476         end; 
     1478      //Reject any value containing a "^"
     1479      //Do we need an @ here as well?
     1480      if (AnsiPos('^',Entry.newvalue) > 0){ or (AnsiPos('@',Entry.newvalue) > 0)} then begin
     1481         messagedlg('Invalid value entered for ' + Entry.Fieldname + #13 + #10
     1482                     + #13 + #10 + 'Invalid Entry:   ' + Entry.newvalue + #13 + #10 +
     1483                     'Ignoring Value.',mtError,[mbOK],0);
     1484      end else begin
     1485         if Entry.oldValue <> Entry.newValue then begin
     1486           if (Entry.newValue <> CLICK_FOR_SUBS) and
     1487              (Entry.newValue <> COMPUTED_FIELD) and
     1488              (Entry.newValue <> CLICK_TO_EDIT) then begin
     1489             oneEntry := Entry.FileNum + '^' + Entry.IENS + '^' + Entry.Field + '^' + Entry.FieldName;
     1490             //Test to see if change is an AV Code (2 or 11) or ES Code (20.4) in User File (200)
     1491             //If so, make it uppercase.       8/12/09   elh
     1492             if Entry.FileNum = '200' then begin
     1493                if ((Entry.Field = '2') and (UCaseOnly = true)) or
     1494                   ((Entry.Field = '11') and (UCaseOnly = true)) or
     1495                   ((Entry.Field = '20.4') and (UCaseOnly = true)) then begin
     1496                   messagedlg('Converting ' + Entry.Fieldname + ' to uppercase for VistA interactivity.' +#13 +#10 +
     1497                              #13 +#10 +
     1498                              'Old Value: ' + Entry.newvalue + '  ' + 'New Value: ' + Uppercase(Entry.newvalue),
     1499                              mtinformation,[mbOK],0);
     1500                   Entry.newValue := Uppercase(Entry.newValue);
     1501                end;
     1502             end;
     1503             oneEntry := oneEntry + '^' + Entry.newValue + '^' + Entry.oldValue;
     1504             Changes.Add(oneEntry);
     1505           end;
     1506         end;
    14771507      end;
    14781508    end;
    14791509  end;
    14801510
    1481  
     1511
    14821512  function TMainForm.PostChanges(Grid : TStringGrid) : TModalResult;
    14831513  //Results:  mrNone -- no post done (not needed)
     
    17051735    SrchStr := FileNum + '^' + FieldNum + '^' + HelpStyle;
    17061736    Idx := CachedHelpIdx.IndexOf(SrchStr);
    1707     if Idx = -1 then begin   
     1737    if Idx = -1 then begin
    17081738      RPCBrokerV.remoteprocedure := 'TMG CHANNEL';
    17091739      RPCBrokerV.param[0].ptype := list;
     
    17181748      end else begin
    17191749        RPCBrokerV.Results.Delete(0);
    1720         if RPCBrokerV.Results.Strings[RPCBrokerV.Results.Count-1]='' then begin
    1721           RPCBrokerV.Results.Delete(RPCBrokerV.Results.Count-1);
     1750        if RPCBrokerV.Results.Count > 0 then begin
     1751          if RPCBrokerV.Results.Strings[RPCBrokerV.Results.Count-1]='' then begin
     1752            RPCBrokerV.Results.Delete(RPCBrokerV.Results.Count-1);
     1753          end;
    17221754        end;
    1723         result := RPCBrokerV.Results.Text;       
     1755        result := RPCBrokerV.Results.Text;
     1756        if result = '' then result := ' ';
    17241757        //Maybe later replace text with "Enter F1 for more help."
    1725         Result := AnsiReplaceText(Result,'Enter ''??'' for more help.','');       
     1758        Result := AnsiReplaceText(Result,'Enter ''??'' for more help.','');
    17261759        while Result[Length(Result)] in [#10,#13] do begin
    17271760          Result := AnsiLeftStr(Result,Length(Result)-1);
     
    21262159        SetPiece(oneEntry,'^',2,IENS);
    21272160        Data.Add(oneEntry);
    2128       end;   
     2161      end;
    21292162    end; 
    21302163  end;
    2131  
    2132  
     2164
     2165
    21332166  procedure TMainForm.ApplicationEventsException(Sender: TObject; E: Exception);
    21342167  begin
     
    21782211  end;
    21792212
     2213
     2214
    21802215end.
    21812216
  • cprs/branches/GUI-config/PostU.dfm

    r476 r542  
    11object PostForm: TPostForm
    2   Left = 83
    3   Top = 285
     2  Left = 1059
     3  Top = 337
    44  Width = 735
    55  Height = 342
  • cprs/branches/GUI-config/PostU.pas

    r476 r542  
    4040{$R *.dfm}
    4141uses
    42   ORNet, ORFn, ORCtrls, Trpcb, FMErrorU, StrUtils;
     42  ORNet, ORFn, ORCtrls,
     43  Trpcb, // needed for .ptype types
     44  FMErrorU, StrUtils;
    4345
    4446  procedure TPostForm.PrepForm(Changes : TStringList);
  • cprs/branches/GUI-config/SetSelU.dfm

    r476 r542  
    11object SetSelForm: TSetSelForm
    2   Left = 529
    3   Top = 124
     2  Left = 1322
     3  Top = 417
    44  Width = 240
    55  Height = 70
  • cprs/branches/GUI-config/SubfilesU.dfm

    r476 r542  
    11object SubfileForm: TSubfileForm
    2   Left = 239
    3   Top = 266
     2  Left = 58
     3  Top = 196
    44  Width = 769
    55  Height = 385
  • cprs/branches/GUI-config/SubfilesU.pas

    r476 r542  
    9595
    9696uses
    97   ORNet, ORFn, ORCtrls, Trpcb,
     97  ORNet, ORFn, ORCtrls,
     98  Trpcb,  //needed for .ptype types
    9899  ToolWin, SelDateTimeU, SetSelU, LookupU, PostU, FMErrorU;
    99100
  • cprs/branches/GUI-config/frmSplash.dfm

    r476 r542  
    44  BorderStyle = bsNone
    55  Caption = 'SplashForm'
    6   ClientHeight = 300
     6  ClientHeight = 298
    77  ClientWidth = 400
    88  Color = clBtnFace
     
    2020    Top = 0
    2121    Width = 400
    22     Height = 300
     22    Height = 298
    2323    Align = alClient
    2424    Picture.Data = {
Note: See TracChangeset for help on using the changeset viewer.