• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 194
  • Last Modified:

Is there something similar to the form event "Load" for a Tab Page?

Hi all,
I know that for a form there is a event called "Load". What I am looking for is an event like "Load" except for a Tab Page. I have some code that needs to run when the tab page is selected.

Thanks, MT
0
MajikTara
Asked:
MajikTara
1 Solution
 
iboutchkineCommented:
You can try TabControl.SelectedTab

something like

If TabControl.SelectedTab = [name of tab page] then
  'run your code


or you can try click event

The tabcontrol's click event is fired and you can get the name of the tabpage like this:

CType(sender, TabControl).SelectedTab.Name
or your other code
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now