Защита информации в системах дистанционного обучения с монопольным доступом

Реферат - Компьютеры, программирование

Другие рефераты по предмету Компьютеры, программирование

bsp;

4.4.3. Visual Basic

 

. , , . , . " " " ". . . , .

. 8 .

Private Sub Edit_Click()

orm1.ole_doc.DoVerb

End Sub

 

Private Sub Form_Load()

Form1.ole_doc.Format = "Rich Text Format"

End Sub

 

Private Sub Load_Click()

Open "c:\temp\temp.rtf" For Input As #1

Dim str, tmp

Do While Not EOF(1)

Input #1, tmp

str = str + tmp

Loop

Close #1

Form1.ole_doc.DoVerb vbOLEDiscardUndoState

Form1.ole_doc.DataText = str

Form1.ole_doc.Update

End Sub

 

Private Sub Save_Click()

Dim msg

Form1.ole_doc.DoVerb vbOLEDiscardUndoState

msg = Form1.ole_doc.DataText

Open "c:\temp\temp.rtf" For Output As #1

Print #1, msg

Close #1

End Sub

 

Private Sub ViewResult_Click()

Open "c:\temp\result.txt" For Input As #1

Dim n As Integer

Input #1, n

Close #1

result = n

End Sub

8.

, , . , , . .. , , , .. , , . . . , . , . 9 .

Private Sub SaveResult(a)

Open "c:\temp\result.txt" For Output As #1

Print #1, a

Close #1

End

 

End Sub

Private Sub Command1_Click(Index As Integer)

SaveResult (2)

End Sub

 

Private Sub Command2_Click()

SaveResult (2)

End Sub

 

Private Sub Command3_Click()

SaveResult (5)

End Sub

 

Private Sub Command4_Click()

SaveResult (2)

End Sub

 

Private Sub Form_Load()

Form1.ole_doc.Format = "Rich Text Format"

Open "c:\temp\temp.rtf" For Input As #1

Dim str, tmp

Do While Not EOF(1)

Input #1, tmp

str = str + tmp

Loop

Close #1

Form1.ole_doc.DoVerb vbOLEDiscardUndoState

Form1.ole_doc.DataText = str

Form1.ole_doc.Update

End Sub

9.

.