Hi,
I have a problem concerning the Form_Loading event:
When I want to load a new Form (ImageDisplay) the ImageDisplay_Load Event is not executed first.
Instead it runs through the global variables definitions and then executes a Private Sub called numericupdown1_changed.
The numericupdown1 field is part of the form I want to load and has not been touched.
That is my calling sequence:
Code:Private Sub Dispalydata_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Dispalydata.Click Dim myDisplay As New ImageDisplay If myDisplay.Created = False Then ImageDisplay.Show() Else ImageDisplay.BringToFront() End If End Sub
This is the form which should get loaded:
The strange thing is that for other forms in my code it works well and starts with the form_load function.Code:Public Class ImageDisplay Dim lambda As Integer = 350 Dim DataTags As Boolean = True Dim DataPoints As Double(,) Private m_BufferBitmap As Bitmap Private m_BufferGraphics As Graphics Public x_samplesize As Integer = Main.NumericUpDown1X.Value Public y_samplesize As Integer = Main.NumericUpDown1y.Value Public currentxpos As Integer = 0 Public currentypos As Integer = 0 Private Sub ImageDisplay_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load .... 'Initialize End Sub
Any guesses where to look at to get rid of this error?
Thanks in advance




Reply With Quote