You are on page 1of 4

VERSION 5.00 Begin VB.

Form Frm1 Caption = "Bang cuu chuong" ClientHeight = 7875 ClientLeft = 120 ClientTop = 450 ClientWidth = 15270 LinkTopic = "Form1" ScaleHeight = 7875 ScaleWidth = 15270 StartUpPosition = 3 'Windows Default Begin VB.CommandButton Cmd3 Caption = "Thoat" Height = 615 Index = 1 Left = 10200 TabIndex = 11 Top = 5520 Width = 4215 End Begin VB.CommandButton Cmd2 Caption = "Xem cuu chuong 2 den 9" Height = 615 Index = 1 Left = 10200 TabIndex = 10 Top = 4440 Width = 4215 End Begin VB.CommandButton Cmd1 Caption = "Xem cuu chuong may!" Height = 615 Index = 0 Left = 10200 TabIndex = 9 Top = 3360 Width = 4215 End Begin VB.Label Lbl9 Height = 2415 Index = 1 Left = 11400 TabIndex = 8 Top = 480 Width = 1575 End Begin VB.Label Lbl8 Height = 2415 Index = 1 Left = 7080 TabIndex = 7 Top = 3360 Width = 1575 End Begin VB.Label Lbl7 Height = 2415 Index = 1 Left = 5040 TabIndex = 6 Top = 3360

Width End Begin VB.Label Height Index Left TabIndex Top Width End Begin VB.Label Height Index Left TabIndex Top Width End Begin VB.Label Height Index Left TabIndex Top Width End Begin VB.Label Height Index Left TabIndex Top Width End Begin VB.Label Height Index Left TabIndex Top Width End Begin VB.Label Height Index Left TabIndex Top Width End

= Lbl6 = = = = = = Lbl5 = = = = = = Lbl4 = = = = = = Lbl3 = = = = = = Lbl2 = = = = = = Lbl1 = = = = = =

1575 2415 1 2880 5 3480 1575 2415 1 720 4 3480 1575 2415 1 7080 3 480 1575 2415 1 5040 2 480 1575 2415 1 2880 1 480 1575 2415 0 720 0 480 1575

End Attribute VB_Name = "Frm1" Attribute VB_GlobalNameSpace = False Attribute VB_Creatable = False Attribute VB_PredeclaredId = True Attribute VB_Exposed = False Private Sub Cmd1_Click() Dim i As Integer Dim j As Integer Dim Xh As String

Dim Ch As String Xh = Chr(13) & Chr(10) For i = 1 To 9 For j = 1 To 9 If i = 2 Then Ch = Ch & " " & i & " x " & j Lbl1 = Right(Ch, Len(Ch) - 1) End If If i = 3 Then Ch = Ch & " " & i & " x " & j Lbl2 = Right(Ch, Len(Ch) - 1) End If If i = 4 Then Ch = Ch & " " & i & " x " & j Lbl3 = Right(Ch, Len(Ch) - 1) End If If i = 5 Then Ch = Ch & " " & i & " x " & j Lbl4 = Right(Ch, Len(Ch) - 1) End If If i = 6 Then Ch = Ch & " " & i & " x " & j Lbl5 = Right(Ch, Len(Ch) - 1) End If If i = 7 Then Ch = Ch & " " & i & " x " & j Lbl6 = Right(Ch, Len(Ch) - 1) End If If i = 8 Then Ch = Ch & " " & i & " x " & j Lbl7 = Right(Ch, Len(Ch) - 1) End If If i = 9 Then Ch = Ch & " " & i & " x " & j Lbl8 = Right(Ch, Len(Ch) - 1) End If Next Next Ch = " " End Sub

& " = " & i * j & Xh

& " = " & i * j & Xh

& " = " & i * j & Xh

& " = " & i * j & Xh

& " = " & i * j & Xh

& " = " & i * j & Xh

& " = " & i * j & Xh

& " = " & i * j & Xh

Private Sub Cmd2_Click() Dim i As Integer Dim j As Integer Dim n As Integer Dim Xh As String Dim Ch As String Xh = Chr(13) & Chr(10) n = InputBox("Ban thich xem cuu chuong may?") For i = 1 To n For j = 1 To 9 Ch = Ch & " " & i & " x " & j & " = " & i * j & Xh Next Next Lbl9 = Right(Ch, Len(Ch) - 1) End Sub Private Sub Cmd3_Click() End

End Sub

You might also like