Public Class Slip20
Dim s As New SaveFileDialog
Dim fname As String
Dim f As New FontDialog
Dim c As New ColorDialog
Dim op As New OpenFileDialog
Private Sub FontStyleToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles FontStyleToolStripMenuItem.Click
If f.ShowDialog() = Windows.Forms.DialogResult.OK Then
RichTextBox1.Font = f.Font
End If
End Sub
Private Sub FontColorToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles FontColorToolStripMenuItem.Click
If c.ShowDialog() = Windows.Forms.DialogResult.OK Then
RichTextBox1.ForeColor = c.Color
End If
End Sub
Private Sub SaveToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles SaveToolStripMenuItem.Click
If s.ShowDialog = Windows.Forms.DialogResult.OK Then
fname = s.FileName
End If
End Sub
Private Sub OpenToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles OpenToolStripMenuItem.Click
If op.ShowDialog = Windows.Forms.DialogResult.OK Then
op.OpenFile()
End If
End Sub
End Class