Dim
t
As
Long
Dim
l
As
Long
Dim
i
As
Integer
Private
Sub
Command1_Click()
On
Error
GoTo
sa
Dim
ctl
As
Control
Dim
ctlType
As
String
Dim
ctlName
As
String
i = i + 1
Set
ctl = Form1.Controls.Add(
"VB.TextBox"
,
"Text"
& i, Form1)
With
ctl
.Visible =
True
.Top = 800 * i
.Left = 400
.Width = 4000
.Height = 400
.Font.Size = 12
.Text =
"Developed By Sachin Dhillan"
.Appearance = 0
End
With
Exit
Sub
sa:
MsgBox Err.Description, vbInformation,
"Error"
End
Sub
Private
Sub
Command2_Click()
On
Error
GoTo
er
If
i = 0
Then
Exit
Sub
Form1.Controls.Remove
"Text"
& i
i = i - 1
Exit
Sub
er:
MsgBox Err.Description, ,
"Warning"
End
Sub
Private
Sub
Form_Load()
t = 500
i = 0
End
Sub
Private
Sub
Form_QueryUnload(Cancel
As
Integer
, UnloadMode
As
Integer
)
If
UnloadMode <> vbFormCode
Then
MsgBox
"Sorry User"
& vbCrLf &
"Use the Exit button to close the Form"
, vbCritical,
"Warning"
Cancel =
True
End
If
End
Sub
İyİ Çalışmalar
20***MRCPLUS***04
email:mrcplus@mynet.com