I am sure that my paint application is correct but when i open image in my app and try to draw on it the drawing didnt show but whaen i save the drawing show on the image:
This is my code for open image:
This is my code for open image:
Code:
Private Sub OpenToolStripMenuItem_Click(sender As System.Object, e As System.EventArgs) Handles OpenToolStripMenuItem.Click
Panel2.Enabled = True
PictureBox.BackColor = Color.White
Dim open As New OpenFileDialog()
open.Filter = "Image Files(*.png; *.jpg; *.bmp)|*.png; *.jpg; *.bmp"
bmpPic = New Bitmap(PictureBox.Width, PictureBox.Height)
If open.ShowDialog() = DialogResult.OK Then
Dim fileName As String = System.IO.Path.GetFullPath(open.FileName)
PictureBox.Image = New Bitmap(open.FileName)
PictureBox.SizeMode = PictureBoxSizeMode.StretchImage
G = System.Drawing.Graphics.FromImage(bmpPic)
PictureBox.DrawToBitmap(bmpPic, PictureBox.ClientRectangle)
End If
End Sub