jangan ragukan kemampuanmu .....!!!!!!!!!!!

PINDAHKAN DATA MAHASISWA DARI FORM1 KE FORM3

Project












LISTING PROGRAM

Dim jk As String
Private Sub Command1_Click()
Form2.Show
End Sub

Private Sub Command2_Click()
Text1.Text = ""
Text2.Text = ""
Text3.Text = ""
Text1.SetFocus
End Sub

Private Sub Command3_Click()
Text1.Enabled = True
Text2.Enabled = True
Text3.Enabled = True
Text4.Enabled = True
Text1.SetFocus
End Sub

Private Sub Form_Load()
Text1.Enabled = False
Text2.Enabled = False
Text3.Enabled = False
Text4.Enabled = False
End Sub

Private Sub Option1_Click()
If Option1.Value = True Then
jk = "pria"
Text4.Text = jk
End If

End Sub

Private Sub Option2_Click()
If Option2.Value = True Then
jk = "wanita"
Text4.Text = jk
End If
End Sub
Private Sub Text1_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
    If Not IsNumeric(Text1.Text) Then
        MsgBox "data yang ditampung hanya angka", vbOKOnly, "sistem informasi"
        Text2.Enabled = False
        Text1.SetFocus
        Text1.Text = ""
        ElseIf Len(Text1.Text) > 9 Then
        MsgBox "NIM anda terlalu panjang", vbOKOnly, "sistem informasi"
        Text2.Enabled = False
        Text1.SetFocus
        Text1.Text = ""
    Else
    Text2.Enabled = True
    Text2.SetFocus
End If
End If
End Sub
Private Sub Text2_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
    If IsNumeric(Text2.Text) Then
        MsgBox "data yang ditampung hanya huruf", vbOKOnly, "sistem informasi"
        Text3.Enabled = False
        Text2.SetFocus
        Text2.Text = ""
        ElseIf Len(Text2.Text) >= 20 Then
        MsgBox "Nama anda terlalu panjang", vbOKOnly, "sistem informasi"
        Text3.Enabled = False
        Text2.SetFocus
        Text2.Text = ""
    Else
    Text3.Enabled = True
    Text3.SetFocus
End If
End If
End Sub
Private Sub Text3_KeyPress(KeyAscii As Integer)
If KeyAscii = 13 Then
    If IsNumeric(Text3.Text) Then
        MsgBox "data yang ditampung hanya huruf", vbOKOnly, "sistem informasi"
        Text4.Enabled = False
        Text3.SetFocus
        Text3.Text = ""
        ElseIf Len(Text3.Text) >= 50 Then
        MsgBox "alamat anda terlalu panjang", vbOKOnly, "sistem informasi"
        Text4.Enabled = False
        Text3.SetFocus
        Text3.Text = ""
    Else
    Text4.Enabled = True
    Text4.SetFocus
End If
End If
End Sub

Private Sub Command1_Click()
Form3.Show
Form1.Enabled = True
Form3.Text1.Text = Form1.Text1.Text
Form3.Text2.Text = Form1.Text2.Text
Form3.Text3.Text = Form1.Text3.Text
Form3.Text4.Text = Form1.Text4.Text
End Sub

Private Sub Command1_Click()
End
End Sub

Private Sub Command1_Click()
Form3.Show
Form1.Enabled = True
Form3.Text1.Text = Form1.Text1.Text
Form3.Text2.Text = Form1.Text2.Text
Form3.Text3.Text = Form1.Text3.Text
Form3.Text4.Text = Form1.Text4.Text
End Sub

OUTPUT





















1 komentar:

Google calendar Embed

Video Gallery Pro

Puzzle Bobble