G
Guest
I am using the following code to get a background image for my form
Private Sub mnuBgroundImage_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles mnuBgroundImage.Clic
If OpenFileDialog1.ShowDialog() = DialogResult.OK The
Dim sr As New System.IO.StreamReader(OpenFileDialog1.FileName
Me.BackgroundImage = Image.FromFile(OpenFileDialog1.FileName
sr.Close(
End I
End Su
This works great. However, this is on frmMain and when I switch to form2 and then return to frmMain the background image is gone. What am I missing here
Thank you
John
Private Sub mnuBgroundImage_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles mnuBgroundImage.Clic
If OpenFileDialog1.ShowDialog() = DialogResult.OK The
Dim sr As New System.IO.StreamReader(OpenFileDialog1.FileName
Me.BackgroundImage = Image.FromFile(OpenFileDialog1.FileName
sr.Close(
End I
End Su
This works great. However, this is on frmMain and when I switch to form2 and then return to frmMain the background image is gone. What am I missing here
Thank you
John