-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathUnitAdd.pas
More file actions
41 lines (33 loc) · 767 Bytes
/
UnitAdd.pas
File metadata and controls
41 lines (33 loc) · 767 Bytes
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
unit UnitAdd;
interface
uses
Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants, System.Classes, Vcl.Graphics,
Vcl.Controls, Vcl.Forms, Vcl.Dialogs, Vcl.StdCtrls;
type
TFormAddress = class(TForm)
Label1: TLabel;
Edit1: TEdit;
OKBtn: TButton;
procedure OKBtnClick(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
endereco : string;
end;
var
FormAddress: TFormAddress;
implementation
{$R *.dfm}
procedure TFormAddress.OKBtnClick(Sender: TObject);
begin
if Edit1.Text='' then
ShowMessage('Enter a valid IP address')
else
begin
endereco:=Edit1.Text;
Edit1.Text:='';
Visible:=false
end;
end;
end.