IgnaceMaes / MaterialSkin

Theming .NET WinForms, C# or VB.Net, to Google's Material Design Principles.
MIT License
2.84k stars 831 forks source link

Clicked Event for TabControl #117

Closed muscaiu closed 7 years ago

muscaiu commented 7 years ago

I want to refresh some things when the user navigates to a specific Tab.

Is it possbile to get Clicked Event for clicking on each specific TabControl?

lucasdavidferrero commented 7 years ago

Hi, you can use the Selecting event of materialTabControl. Here a example:

`private void tabControlTurnos_Selecting(object sender, TabControlCancelEventArgs e) { if (e.TabPageIndex==1) { MessageBox.Show("hello!");

        }
    }`

The TabPageIndex is a specific tab, can be 0,1,2... like a array.

muscaiu commented 7 years ago

Thanks @lucasdavidferrero ! That's just what i was looking for.