-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathFormTambahGolonganDarah.frm
239 lines (235 loc) · 8.55 KB
/
FormTambahGolonganDarah.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
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
VERSION 5.00
Object = "{02353968-C1C9-4E0A-88D3-18759BDC60FE}#1.0#0"; "AeroSuite.ocx"
Object = "{5DC43A6F-8B43-4A60-A977-95A8CDDD093A}#1.0#0"; "dcButton.ocx"
Object = "{530871E2-C21C-4628-9427-E2C09620063B}#1.0#0"; "XP_Engine.ocx"
Begin VB.Form FormTambahGolonganDarah
BackColor = &H00E0E0E0&
BorderStyle = 1 'Fixed Single
Caption = "Tambah Golongan Darah"
ClientHeight = 1440
ClientLeft = 45
ClientTop = 375
ClientWidth = 3720
BeginProperty Font
Name = "Niagara Engraved"
Size = 9.75
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Icon = "FormTambahGolonganDarah.frx":0000
LinkTopic = "Form1"
MaxButton = 0 'False
MinButton = 0 'False
ScaleHeight = 1440
ScaleWidth = 3720
ShowInTaskbar = 0 'False
StartUpPosition = 2 'CenterScreen
Begin Dacara_dcButton.dcButton cmOK
Height = 375
Left = 2160
TabIndex = 2
Top = 960
Width = 1455
_ExtentX = 2566
_ExtentY = 661
BackColor = 12230304
ButtonStyle = 3
Caption = "OK/Simpan"
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "Agency FB"
Size = 9.75
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
PicAlign = 5
PicDown = "FormTambahGolonganDarah.frx":0442
PicHot = "FormTambahGolonganDarah.frx":0794
PicNormal = "FormTambahGolonganDarah.frx":0AE6
PicSize = 1
PicSizeH = 16
PicSizeW = 16
End
Begin AeroSuite.AeroTextBox textGolonganDarah
Height = 375
Left = 120
TabIndex = 1
Top = 480
Width = 3495
_ExtentX = 6165
_ExtentY = 661
BackColor = 16777215
ForeColor = -2147483630
BeginProperty Font {0BE35203-8F91-11CE-9DE3-00AA004BB851}
Name = "Segoe UI"
Size = 9
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Text = "AeroTextBox1"
End
Begin XPEngine.XPControl XP_Engine
Left = 0
Top = 0
_ExtentX = 529
_ExtentY = 503
ColorScheme = 2
End
Begin VB.Label Label1
AutoSize = -1 'True
BackStyle = 0 'Transparent
Caption = "Tambah Golongan Darah : "
BeginProperty Font
Name = "Nina"
Size = 9.75
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 240
Left = 120
TabIndex = 0
Top = 120
Width = 2025
End
End
Attribute VB_Name = "FormTambahGolonganDarah"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Option Explicit
Private Sub cmOK_Click()
On Error GoTo BinasakanlahError
If textGolonganDarah.Text = "" Then
If FormPengaturan.cmbBahasa.ListIndex = 0 Then
MsgBox "Maaf, input tidak boleh kosong!", vbExclamation + vbOKOnly, ""
Else
MsgBox "Sorry, value don't empty!", vbExclamation + vbOKOnly, ""
End If
Else
With Form_IDENTITAS_PRIBADI
.AdodcGolonganDarah.Recordset.AddNew
.AdodcGolonganDarah.Recordset.Fields(0).Value = textGolonganDarah.Text
.AdodcGolonganDarah.Recordset.Update
.AdodcGolonganDarah.Refresh
.cmbGolonganDarah.Clear
Do Until .AdodcGolonganDarah.Recordset.EOF
.cmbGolonganDarah.AddItem .AdodcGolonganDarah.Recordset.Fields(0).Value
.AdodcGolonganDarah.Recordset.MoveNext
Loop
.cmbGolonganDarah.Text = textGolonganDarah.Text
End With
Unload Me
End If
Exit Sub
BinasakanlahError:
HancurkanError
Form_IDENTITAS_PRIBADI.AdodcGolonganDarah.Refresh
End Sub
Private Sub Form_Load()
NyambunggUtama
PENGATURAN_WARNA
PENGATURAN_BAHASA
'PENGATURAN UNTUK ALWAYS ON TOP
If FormPengaturan.cekAlwaysOnTop.Value = Checked Then
SetOnTop (Me.hwnd)
ElseIf FormPengaturan.cekAlwaysOnTop.Value = Unchecked Then
NotOnTop (Me.hwnd)
End If
For Each Objek In Me
If TypeName(Objek) = "Label" Or TypeName(Objek) = "dcButton" Or TypeName(Objek) = "AeroCheckBox" Or TypeName(Objek) = "TextBox" Or TypeName(Objek) = "ComboBox" Then
With Objek
.Font.Name = "Agency FB"
.Font.Size = 11
End With
End If
If TypeName(Objek) = "XPText" Then Objek.Font.Name = "Agency FB"
Next
XP_Engine.StartEngine
End Sub
Sub PENGATURAN_WARNA()
'PENGATURAN WARNA UNTUK FORM INI
For Each Objek In Me
Select Case FormPengaturan.cmbWarnaTampilan.ListIndex
Case Is = 0 'Ungu Natural
Me.BackColor = UnguNatural
If TypeName(Objek) = "dcButton" Then Objek.BackColor = UnguNatural
Case Is = 1 'Merah
Me.BackColor = Merah
If TypeName(Objek) = "dcButton" Then Objek.BackColor = Merah
Case Is = 2 'Pink
Me.BackColor = Pink
If TypeName(Objek) = "dcButton" Then Objek.BackColor = Pink
Case Is = 3 'HijauMuda
Me.BackColor = HijauMuda
If TypeName(Objek) = "dcButton" Then Objek.BackColor = HijauMuda
Case Is = 4 'Hitam
Me.BackColor = Hitam
If TypeName(Objek) = "dcButton" Then Objek.BackColor = Hitam
Case Is = 5 'Silver
Me.BackColor = Silver
If TypeName(Objek) = "dcButton" Then Objek.BackColor = Silver
Case Is = 6 'SilverNatural
Me.BackColor = SilverNatural
If TypeName(Objek) = "dcButton" Then Objek.BackColor = SilverNatural
Case Is = 7 'Orange
Me.BackColor = Orange
If TypeName(Objek) = "dcButton" Then Objek.BackColor = Orange
Case Is = 8 'UnguJanda
Me.BackColor = UnguJanda
If TypeName(Objek) = "dcButton" Then Objek.BackColor = UnguJanda
End Select
Next
'PENGATURAN THEMA UNTUK FORM INI
For Each Objek In Me
If TypeName(Objek) = "dcButton" Then
Select Case FormPengaturan.cmbTemaTampilan.ListIndex
Case Is = 0 'RST_Office 2003
Objek.ButtonStyle = 3
Objek.BackColor = &HC0C0C0
Case Is = 1 'RST_Office XP
Objek.ButtonStyle = 4
Case Is = 2 'RST_Opera Browser
Objek.ButtonStyle = 5
Case Is = 3 'RST_Classic
Objek.ButtonStyle = 6
Case Is = 4 'RST_XP Blue
Objek.ButtonStyle = 7
Case Is = 5 'RST_XP Olive Green
Objek.ButtonStyle = 8
Case Is = 6 'RST_XP Silver
Objek.ButtonStyle = 9
Case Is = 7 'RST_XP Toolbar
Objek.ButtonStyle = 10
Case Is = 8 'RST_Yahoo
Objek.ButtonStyle = 11
Objek.BackColor = &H12BCFF
Case Is = 9 'RST_Mac
Objek.ButtonStyle = 1
Objek.BackColor = &HFF9B48
Case Is = 10 'RST_MacOSX
Objek.ButtonStyle = 2
End Select
End If
Next
End Sub
Sub PENGATURAN_BAHASA()
If FormPengaturan.cmbBahasa.ListIndex = 0 Then
Label1.Caption = "Tambah Golongan Darah : "
cmOK.Caption = "&OK/Simpan"
ElseIf FormPengaturan.cmbBahasa.ListIndex = 1 Then
Label1.Caption = "Add New Blood Type : "
cmOK.Caption = "&OK/Save"
End If
End Sub