
- •Содержание
- •Введение
- •1 Цели и задачи учебной практики
- •2 Краткая характеристика места прохождения практики
- •2.1 Характеристика аппаратного обеспечения
- •2.2 Характеристика программного обеспечения
- •3 Теоретическая часть
- •4 Практическая часть
- •4.1 Постановка задачи
- •4.2 Описание программы
- •4.3 Блок-схема программы
- •Заключение
- •Список использованных источников
Список использованных источников
Википедия. – [Электронный ресурс]. Режим доступа: http:// ru.wikipedia.org
Михеев, Р. VBA и программирование в MS Office для пользователей: учебное пособие / Р. Михеев. – Москва: Форум–Инфра–М, 2008. – 360с.
Новикова, Ф.А. Microsoft Office 2000: разработка приложений / А.Ю. Гарнаев, Ф. А. Новикова; под общ. ред. Ф.А. Новикова. - СПб.: БХВ – Санкт-Петербург, 2000. – 656 с.
Процессы и потоки. — [Электронный ресурс]. Режим доступа: http:// ru.wikipedia.org, дата доступа: 04.04.2012
Приложение А
Листинг программы в VBA
Private Sub Label9_Click()
If (Label18.Caption / 2 = Label18.Caption \ 2) Then
TextBox1.Text = "o"
Label9.Visible = False
Else
TextBox1.Text = "x"
Label9.Visible = False
End If
Label18.Caption = Label18.Caption + 1
End Sub
Private Sub Label10_Click()
If (Label18.Caption / 2 = Label18.Caption \ 2) Then
TextBox2.Text = "o"
Label10.Visible = False
Else
TextBox2.Text = "x"
Label10.Visible = False
End If
Label18.Caption = Label18.Caption + 1
End Sub
Private Sub Label11_Click()
If (Label18.Caption / 2 = Label18.Caption \ 2) Then
TextBox3.Text = "o"
Label11.Visible = False
Else
TextBox3.Text = "x"
Label11.Visible = False
End If
Label18.Caption = Label18.Caption + 1
End Sub
Private Sub Label12_Click()
If (Label18.Caption / 2 = Label18.Caption \ 2) Then
TextBox4.Text = "o"
Label12.Visible = False
Else
TextBox4.Text = "x"
Label12.Visible = False
End If
Label18.Caption = Label18.Caption + 1
End Sub
Private Sub Label13_Click()
If (Label18.Caption / 2 = Label18.Caption \ 2) Then
TextBox5.Text = "o"
Label13.Visible = False
Else
TextBox5.Text = "x"
Label13.Visible = False
End If
Label18.Caption = Label18.Caption + 1
End Sub
Private Sub Label14_Click()
If (Label18.Caption / 2 = Label18.Caption \ 2) Then
TextBox6.Text = "o"
Label14.Visible = False
Else
TextBox6.Text = "x"
Label14.Visible = False
End If
Label18.Caption = Label18.Caption + 1
End Sub
Private Sub Label15_Click()
If (Label18.Caption / 2 = Label18.Caption \ 2) Then
TextBox7.Text = "o"
Label15.Visible = False
Else
TextBox7.Text = "x"
Label15.Visible = False
End If
Label18.Caption = Label18.Caption + 1
End Sub
Private Sub Label16_Click()
If (Label18.Caption / 2 = Label18.Caption \ 2) Then
TextBox8.Text = "o"
Label16.Visible = False
Else
TextBox8.Text = "x"
Label16.Visible = False
End If
Label18.Caption = Label18.Caption + 1
End Sub
Private Sub Label17_Click()
If (Label18.Caption / 2 = Label18.Caption \ 2) Then
TextBox9.Text = "o"
Label17.Visible = False
Else
TextBox9.Text = "x"
Label17.Visible = False
End If
Label18.Caption = Label18.Caption + 1
End Sub
Private Sub CommandButton1_Click()
Dim nomer As Integer
If Label3.Caption = TextBox10.Text + " WIN" Then
Label7.Caption = Label7.Caption + 1
End If
If Label4.Caption = TextBox11.Text + " WIN" Then
Label8.Caption = Label8.Caption + 1
End If
TextBox1.Text = ""
TextBox2.Text = ""
TextBox3.Text = ""
TextBox4.Text = ""
TextBox5.Text = ""
TextBox6.Text = ""
TextBox7.Text = ""
TextBox8.Text = ""
TextBox9.Text = ""
Label3.Caption = ""
Label4.Caption = ""
Label9.Visible = True
Label10.Visible = True
Label11.Visible = True
Label12.Visible = True
Label13.Visible = True
Label14.Visible = True
Label15.Visible = True
Label16.Visible = True
Label17.Visible = True
End Sub
Private Sub TextBox1_Change()
If TextBox1.Text = "x" And TextBox2.Text = "x" And TextBox3.Text = "x" Then
Label3.Caption = TextBox10.Text + " WIN"
End If
If TextBox1.Text = "x" And TextBox4.Text = "x" And TextBox7.Text = "x" Then
Label3.Caption = TextBox10.Text + " WIN"
End If
If TextBox1.Text = "x" And TextBox5.Text = "x" And TextBox9.Text = "x" Then
Label3.Caption = TextBox10.Text + " WIN"
End If
If TextBox1.Text = "o" And TextBox2.Text = "o" And TextBox3.Text = "o" Then
Label4.Caption = TextBox11.Text + " WIN"
End If
If TextBox1.Text = "o" And TextBox4.Text = "o" And TextBox7.Text = "o" Then
Label4.Caption = TextBox11.Text + " WIN"
End If
If TextBox1.Text = "o" And TextBox5.Text = "o" And TextBox9.Text = "o" Then
Label4.Caption = TextBox11.Text + " WIN"
End If
End Sub
Private Sub TextBox2_Change()
If TextBox1.Text = "x" And TextBox2.Text = "x" And TextBox3.Text = "x" Then
Label3.Caption = TextBox10.Text + " WIN"
End If
If TextBox2.Text = "x" And TextBox5.Text = "x" And TextBox8.Text = "x" Then
Label3.Caption = TextBox10.Text + " WIN"
End If
If TextBox1.Text = "o" And TextBox2.Text = "o" And TextBox3.Text = "o" Then
Label4.Caption = TextBox11.Text + " WIN"
End If
If TextBox2.Text = "o" And TextBox5.Text = "o" And TextBox8.Text = "o" Then
Label4.Caption = TextBox11.Text + " WIN"
End If
End Sub
Private Sub TextBox3_Change()
If TextBox1.Text = "x" And TextBox2.Text = "x" And TextBox3.Text = "x" Then
Label3.Caption = TextBox10.Text + " WIN"
End If
If TextBox3.Text = "x" And TextBox6.Text = "x" And TextBox9.Text = "x" Then
Label3.Caption = TextBox10.Text + " WIN"
End If
If TextBox3.Text = "x" And TextBox5.Text = "x" And TextBox7.Text = "x" Then
Label3.Caption = TextBox10.Text + " WIN"
End If
If TextBox1.Text = "o" And TextBox2.Text = "o" And TextBox3.Text = "o" Then
Label4.Caption = TextBox11.Text + " WIN"
End If
If TextBox3.Text = "o" And TextBox6.Text = "o" And TextBox9.Text = "o" Then
Label4.Caption = TextBox11.Text + " WIN"
End If
If TextBox3.Text = "o" And TextBox5.Text = "o" And TextBox7.Text = "o" Then
Label4.Caption = TextBox11.Text + " WIN"
End If
End Sub
Private Sub TextBox4_Change()
If TextBox1.Text = "x" And TextBox4.Text = "x" And TextBox7.Text = "x" Then
Label3.Caption = TextBox10.Text + " WIN"
End If
If TextBox4.Text = "x" And TextBox5.Text = "x" And TextBox6.Text = "x" Then
Label3.Caption = TextBox10.Text + " WIN"
End If
If TextBox1.Text = "o" And TextBox4.Text = "o" And TextBox7.Text = "o" Then
Label4.Caption = TextBox11.Text + " WIN"
End If
If TextBox4.Text = "o" And TextBox5.Text = "o" And TextBox6.Text = "o" Then
Label4.Caption = TextBox11.Text + " WIN"
End If
End Sub
Private Sub TextBox5_Change()
If TextBox1.Text = "x" And TextBox5.Text = "x" And TextBox9.Text = "x" Then
Label3.Caption = TextBox10.Text + " WIN"
End If
If TextBox4.Text = "x" And TextBox5.Text = "x" And TextBox6.Text = "x" Then
Label3.Caption = TextBox10.Text + " WIN"
End If
If TextBox2.Text = "x" And TextBox5.Text = "x" And TextBox8.Text = "x" Then
Label3.Caption = TextBox10.Text + " WIN"
End If
If TextBox3.Text = "x" And TextBox5.Text = "x" And TextBox7.Text = "x" Then
Label3.Caption = TextBox10.Text + " WIN"
End If
If TextBox1.Text = "o" And TextBox5.Text = "o" And TextBox9.Text = "o" Then
Label4.Caption = TextBox11.Text + " WIN"
End If
If TextBox4.Text = "o" And TextBox5.Text = "o" And TextBox6.Text = "o" Then
Label4.Caption = TextBox11.Text + " WIN"
End If
If TextBox2.Text = "o" And TextBox5.Text = "o" And TextBox8.Text = "o" Then
Label4.Caption = TextBox11.Text + " WIN"
End If
If TextBox3.Text = "o" And TextBox5.Text = "o" And TextBox7.Text = "o" Then
Label4.Caption = TextBox11.Text + " WIN"
End If
End Sub
Private Sub TextBox6_Change()
If TextBox4.Text = "x" And TextBox5.Text = "x" And TextBox6.Text = "x" Then
Label3.Caption = TextBox10.Text + " WIN"
End If
If TextBox3.Text = "x" And TextBox6.Text = "x" And TextBox9.Text = "x" Then
Label3.Caption = TextBox10.Text + " WIN"
End If
If TextBox4.Text = "o" And TextBox5.Text = "o" And TextBox6.Text = "o" Then
Label4.Caption = TextBox11.Text + " WIN"
End If
If TextBox3.Text = "o" And TextBox6.Text = "o" And TextBox9.Text = "o" Then
Label4.Caption = TextBox11.Text + " WIN"
End If
End Sub
Private Sub TextBox7_Change()
If TextBox1.Text = "x" And TextBox4.Text = "x" And TextBox7.Text = "x" Then
Label3.Caption = TextBox10.Text + " WIN"
End If
If TextBox7.Text = "x" And TextBox8.Text = "x" And TextBox9.Text = "x" Then
Label3.Caption = TextBox10.Text + " WIN"
End If
If TextBox3.Text = "x" And TextBox5.Text = "x" And TextBox7.Text = "x" Then
Label3.Caption = TextBox10.Text + " WIN"
End If
If TextBox1.Text = "o" And TextBox4.Text = "o" And TextBox7.Text = "o" Then
Label4.Caption = TextBox11.Text + " WIN"
End If
If TextBox7.Text = "o" And TextBox8.Text = "o" And TextBox9.Text = "o" Then
Label4.Caption = TextBox11.Text + " WIN"
End If
If TextBox3.Text = "o" And TextBox5.Text = "o" And TextBox7.Text = "o" Then
Label4.Caption = TextBox11.Text + " WIN"
End If
End Sub
Private Sub TextBox8_Change()
If TextBox7.Text = "x" And TextBox8.Text = "x" And TextBox9.Text = "x" Then
Label3.Caption = TextBox10.Text + " WIN"
End If
If TextBox2.Text = "x" And TextBox5.Text = "x" And TextBox8.Text = "x" Then
Label3.Caption = TextBox10.Text + " WIN"
End If
If TextBox7.Text = "o" And TextBox8.Text = "o" And TextBox9.Text = "o" Then
Label4.Caption = TextBox11.Text + " WIN"
End If
If TextBox2.Text = "o" And TextBox5.Text = "o" And TextBox8.Text = "o" Then
Label4.Caption = TextBox11.Text + " WIN"
End If
End Sub
Private Sub TextBox9_Change()
If TextBox1.Text = "x" And TextBox5.Text = "x" And TextBox9.Text = "x" Then
Label3.Caption = TextBox10.Text + " WIN"
End If
If TextBox7.Text = "x" And TextBox8.Text = "x" And TextBox9.Text = "x" Then
Label3.Caption = TextBox10.Text + " WIN"
End If
If TextBox3.Text = "x" And TextBox6.Text = "x" And TextBox9.Text = "x" Then
Label3.Caption = TextBox10.Text + " WIN"
End If
If TextBox1.Text = "o" And TextBox5.Text = "o" And TextBox9.Text = "o" Then
Label4.Caption = TextBox11.Text + " WIN"
End If
If TextBox7.Text = "o" And TextBox8.Text = "o" And TextBox9.Text = "o" Then
Label4.Caption = TextBox11.Text + " WIN"
End If
If TextBox3.Text = "o" And TextBox6.Text = "o" And TextBox9.Text = "o" Then
Label4.Caption = TextBox11.Text + " WIN"
End If
End Sub