lothos12345 Posted August 23, 2003 Posted August 23, 2003 In VB.NET does the Form_Load event still function. I try to tell the program to execute code as the form loads but nothing is happening. Is Form_Load still optional? Any help with this question would be greatly appreciated. Quote
*Experts* Volte Posted August 23, 2003 *Experts* Posted August 23, 2003 You can't simply make a sub called Form_Load; it needs to be told to handle the event. Assuming you have the IDE, choose '(Base Class Events)' from the top-left combo in the code window, and choose 'Load' from the right one. The IDE will wire the event for you. You should take notice that it requires a sender object (that's the object that invoked the event), an eventargs object (used as an alternative to a list of parameters), and a Handles statement to tell it the actual event to handle. You no longer need for the sub to be called Form_Load; you can call it anything you want as long as you tell it to Handle Form.Load. Consult your MSDN for more info. :) Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.