HerbAndEdnaWeinstein
Technical User
Hi, I've got a Form that needs to be accessed from various functions and subs in my program. (The program itself runs as an add-in to a larger app.)
So, I designed the form in the designer, named it "Form_Main", and I access it in my class declaration like this:
***************************************************
Private m_pForm_Main As New Form_Main
***************************************************
Then, from within my OnClick() sub, I invoke it like this:
***************************************************
m_pForm_Main.Show()
***************************************************
But, there's a problem. The Form works great the first time I click the start button and the Form opens. The second time I click the start button, however, the program returns an error when it attempts to open the form.
Thanks in advance, I have a feeling it's not too tough!!!
Herbie
So, I designed the form in the designer, named it "Form_Main", and I access it in my class declaration like this:
***************************************************
Private m_pForm_Main As New Form_Main
***************************************************
Then, from within my OnClick() sub, I invoke it like this:
***************************************************
m_pForm_Main.Show()
***************************************************
But, there's a problem. The Form works great the first time I click the start button and the Form opens. The second time I click the start button, however, the program returns an error when it attempts to open the form.
Thanks in advance, I have a feeling it's not too tough!!!
Herbie