I was wondering if there is anyway to make Windows Forms do certain tasks whenever its shown ?
- Thanks in advance Paul
I was wondering if there is anyway to make Windows Forms do certain tasks whenever its shown ?
- Thanks in advance Paul
You can always add timer which starts when form activates.
On timer event should contain what tasks form should do.
Actually what you should do is add an event handler to either the Load event or the VisibleChanged event. It all depends on if you want the code to execute everytime the form is shown, or only the first time the form is shown.
Obviously, use Load if you only want the code to execute the first time. Use VisibleChanged if you want the code to execute everytime the form is shown.
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.