T
Turtle
I have a tab control which permits users to view a variety of data,
depending on the page selected.
However, I need to do a validation before I permit the user to move off the
current page.
The Validating event seems too late for this; if the validation is OK, I
want to display the new data immediately when the new tab is clicked. But
the Validating event doesn't fire until the user leaves the tab control by
clicking something else.
None of the other events seem to offer any sort of Cancel or Undo, so I've
been left stringing together a rather convoluted set of code, where I store
the TabControlIndex on the TabControl_GotFocus event, then return to that
index in the TabControl_SelectedIndexChanged event, causing that event to
fire another time...
Isn't there a better way out there?
TIA
- Turtle
depending on the page selected.
However, I need to do a validation before I permit the user to move off the
current page.
The Validating event seems too late for this; if the validation is OK, I
want to display the new data immediately when the new tab is clicked. But
the Validating event doesn't fire until the user leaves the tab control by
clicking something else.
None of the other events seem to offer any sort of Cancel or Undo, so I've
been left stringing together a rather convoluted set of code, where I store
the TabControlIndex on the TabControl_GotFocus event, then return to that
index in the TabControl_SelectedIndexChanged event, causing that event to
fire another time...
Isn't there a better way out there?
TIA
- Turtle