-
Notifications
You must be signed in to change notification settings - Fork 0
/
DPError.pas
53 lines (42 loc) · 1 KB
/
DPError.pas
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
unit DPError;
interface
uses
System.SysUtils, System.Types, System.UITypes, System.Classes, System.Variants,
FMX.Types, FMX.Controls, FMX.Forms, FMX.Graphics, FMX.Dialogs, FMX.Edit,
FMX.StdCtrls, FMX.Controls.Presentation;
type
TError = class(TForm)
Button1: TButton;
Label1: TLabel;
Label2: TLabel;
Label3: TLabel;
Edit1: TEdit;
Edit2: TEdit;
procedure Button1Click(Sender: TObject);
procedure FormCreate(Sender: TObject);
private
{ Private declarations }
public
Verbose: boolean;
procedure Show(const Name: string; const Value: string);
end;
var
Error: TError;
implementation
{$R *.fmx}
{ TError }
procedure TError.Button1Click(Sender: TObject);
begin
Close;
end;
procedure TError.FormCreate(Sender: TObject);
begin
Verbose := true;
end;
procedure TError.Show(const Name, Value: string);
begin
Error.Edit1.Text := Name;
Error.Edit2.Text := value;
if Verbose then Error.ShowModal;
end;
end.