source: cprs/trunk/CPRS-Chart/Orders/fODRadApproval.pas@ 1676

Last change on this file since 1676 was 829, checked in by Kevin Toppenberg, 14 years ago

Upgrade to version 27

File size: 2.0 KB
Line 
1unit fODRadApproval;
2
3interface
4
5uses Windows, SysUtils, Classes, Graphics, Forms, Controls, StdCtrls,
6 Buttons, ORCtrls, ORfn, ExtCtrls, fBase508Form, VA508AccessibilityManager;
7
8type
9 TfrmODRadApproval = class(TfrmBase508Form)
10 cmdOK: TButton;
11 cmdCancel: TButton;
12 cboRadiologist: TORComboBox;
13 SrcLabel: TLabel;
14 pnlBase: TORAutoPanel;
15 procedure cmdOKClick(Sender: TObject);
16 procedure cmdCancelClick(Sender: TObject);
17 private
18 FRadiologist: string ;
19 FChanged: Boolean;
20 end;
21
22procedure SelectApprovingRadiologist(FontSize: Integer; var Radiologist: string) ;
23
24implementation
25
26{$R *.DFM}
27
28uses rODRad, rCore, uCore;
29
30const
31 TX_RAD_TEXT = 'Select radiologist or press Cancel.';
32 TX_RAD_CAP = 'No Radiologist Selected';
33
34procedure SelectApprovingRadiologist(FontSize: Integer; var Radiologist: string);
35{ displays radiologist selection form and returns a record of the selection }
36var
37 frmODRadApproval: TfrmODRadApproval;
38 W, H: Integer;
39begin
40 frmODRadApproval := TfrmODRadApproval.Create(Application);
41 try
42 with frmODRadApproval do
43 begin
44 Font.Size := FontSize;
45 W := ClientWidth;
46 H := ClientHeight;
47 ResizeToFont(FontSize, W, H);
48 ClientWidth := W; pnlBase.Width := W;
49 ClientHeight := H; pnlBase.Height := H;
50 FChanged := False;
51 FastAssign(SubsetOfRadiologists, cboRadiologist.Items);
52 ShowModal;
53 Radiologist := FRadiologist ;
54 end; {with frmODRadApproval}
55 finally
56 frmODRadApproval.Release;
57 end;
58end;
59
60procedure TfrmODRadApproval.cmdCancelClick(Sender: TObject);
61begin
62 Close;
63end;
64
65procedure TfrmODRadApproval.cmdOKClick(Sender: TObject);
66begin
67 if cboRadiologist.ItemIEN = 0 then
68 begin
69 InfoBox(TX_RAD_TEXT, TX_RAD_CAP, MB_OK or MB_ICONWARNING);
70 FChanged := False ;
71 Exit;
72 end;
73 FChanged := True;
74 FRadiologist := cboRadiologist.Items[cboRadiologist.ItemIndex] ;
75 Close;
76end;
77
78end.
Note: See TracBrowser for help on using the repository browser.