-
Notifications
You must be signed in to change notification settings - Fork 0
/
EnterKey.frm
65 lines (63 loc) · 1.72 KB
/
EnterKey.frm
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
54
55
56
57
58
59
60
61
62
63
64
65
VERSION 5.00
Begin VB.Form EnterKey
BorderStyle = 1 'Fixed Single
Caption = "Ââåäèòå êëþ÷"
ClientHeight = 1725
ClientLeft = 6315
ClientTop = 5850
ClientWidth = 4275
LinkTopic = "Form1"
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 1725
ScaleWidth = 4275
Begin VB.CommandButton OkButton
Caption = "OK"
Height = 375
Left = 3240
TabIndex = 3
Top = 1080
Width = 855
End
Begin VB.TextBox txtKey
Height = 285
Left = 840
TabIndex = 2
Top = 1080
Width = 1935
End
Begin VB.Label Label2
Caption = "Key"
Height = 255
Left = 360
TabIndex = 1
Top = 1080
Width = 375
End
Begin VB.Label Label1
Caption = " òåêñòîâîå ïîëå ââåäèòå 8 çíà÷íûé êëþ÷ äëÿ çàøèôðîâêè òåêñòà."
Height = 495
Left = 120
TabIndex = 0
Top = 240
Width = 3975
End
End
Attribute VB_Name = "EnterKey"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Dim n As Integer
Private Sub OkButton_Click()
If Len(txtKey) <> 8 Then
For n = Len(txtKey) To 7
txtKey = txtKey & " "
Next n
End If
Hide
End Sub
Private Sub txtKey_Change()
If Len(txtKey) > 8 Then MsgBox "Âû äîëæíû ââåñòè íåáîëåå 8 ñèìâîëîâ", vbOKOnly, "Mistake": txtKey = Left(txtKey, 8)
End Sub