Hi All
I have a form that is called by the following code:
Dim frm2 As New frm_form1(param1, param2)
frm2.ShowDialog()
In the "Public Sub New" event of the form, I need to check a value and if this matches, close the form.
So I do...
msgBox("You cannot alter this record"
dispose() ' tried me.close()
after the initialize component.
However, this gives an error in the calling form saying frm_form1 does not exist.
What is the best way of doing this?
I basically want to be able to close my form on startup if a condition is met (without showing it).
Thanks
ITflash
I have a form that is called by the following code:
Dim frm2 As New frm_form1(param1, param2)
frm2.ShowDialog()
In the "Public Sub New" event of the form, I need to check a value and if this matches, close the form.
So I do...
msgBox("You cannot alter this record"
dispose() ' tried me.close()
after the initialize component.
However, this gives an error in the calling form saying frm_form1 does not exist.
What is the best way of doing this?
I basically want to be able to close my form on startup if a condition is met (without showing it).
Thanks
ITflash