Public Class Form1
Private Sub OpenToolStripMenuItem1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles OpenToolStripMenuItem1.Click
Try
Dim dlg As OpenFileDialog = New OpenFileDialog
dlg.Title = "Open"
dlg.Filter = "PNG (*.png)|*.png|JPEG (*.jpeg)|*jpeg|Bitmap (*.bmp)|*bmb"
If dlg.ShowDialog() = System.Windows.Forms.DialogResult.OK Then
PictureBox1.Load(dlg.FileName)
PictureBox2.Hide()
End If
Catch ex As Exception : End Try
End Sub
Private Sub ScaleToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles ScaleToolStripMenuItem.Click
Me.Width = PictureBox1.Width
Me.Height = PictureBox1.Height
End Sub
Private Sub AboutToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles AboutToolStripMenuItem.Click
About.Show()
End Sub
End Class
Attached File(s)
-
Project.pdf (829.5K)
Number of downloads: 31

New Topic/Question
Reply




MultiQuote


|