Click here to Skip to main content
16,015,351 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Good day

I want to add the onload event of a form to the onclick event of the button. The moment I click on the button it must run the onload event of a form.

Any suggestions or articles for the coding?

Thanks
Posted

1 solution

That's kinda bad practice. If it were me, I'd move the code in the Load event handler into a separate method, and then call that method from both the Load handler and the button click handler.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900