I use the TabControl_SelectedIndexChanged event when the user changes tabs. TabControl.SelectedIndex / TabControl.SelectedTab returns only a new tab. Is there any way to get the previous tab? Or should I stick to the obvious preservation of the current tab every time I change tabs?
I want to use this to undo tab changes under certain conditions, for example, there are unsaved changes.
source share