Initialize event doesn't work

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Dear all
I have create a form A and in the initialize event I have write some codes in it
But when I load the form second times, it seem that those code didn't work anymore
What happen is that I click the terminate button(the X button on the top right corrner) on form A and load & show form B, from form B I load form A again and all the controls in form A didn't works anymore

How to disable the terminate button on a form?
 
Hi Pop,

The Initialize event only fires one time, when the UserForm is first
created. If you hide and then re-show the UserForm and you want to run some
code, you should use the Activate event instead. This event will fire
whenever the UserForm is displayed from a hidden state.

--
Rob Bovey, MCSE, MCSD, Excel MVP
Application Professionals
http://www.appspro.com/

* Please post all replies to this newsgroup *
* I delete all unsolicited e-mail responses *


Pop said:
Dear all,
I have create a form A and in the initialize event I have write some codes in it.
But when I load the form second times, it seem that those code didn't work anymore.
What happen is that I click the terminate button(the X button on the top
right corrner) on form A and load & show form B, from form B I load form A
again and all the controls in form A didn't works anymore.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top