Jump to content
Xtreme .Net Talk

Recommended Posts

Posted
I am hiding forms instead of closing them because that is what my program requires. When I call the hidden forms, I need for them to run their load events or any other event for that matter. Is there an event that is run when a form is hidden and is called or is there some other way I have to go about doing this? Thanks for your time!
  • *Experts*
Posted

Yep, try the form activated event. If the form is hidden or the user just pages into another program for a bit then comes back this event will be activated...hence the name I guess.

 

Hope that'll help

Dan

Member, in good standing, of the elite fraternity of mentally challenged programmers.

 

Dolphins Software

Posted
But this event will be fired EVERY time the user switches back to that form, not just when the form is first shown. You should be able to make the Form_Load event Public, then when you do frm.Show (assuming you've Dimmed the form somewhere), use frm.Form_Load after it. Since my notebook with .Net installed is out for repairs, I have no way to test this.
  • *Experts*
Posted

Okay, then either set a public variable in form1's load form2 button event or a public variable in form2's close event that is read in form2's activated event. I think that will accomplish what you are looking for.

 

Dan

Member, in good standing, of the elite fraternity of mentally challenged programmers.

 

Dolphins Software

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...