SStab control tab click , activating tab 
Author Message
 SStab control tab click , activating tab
Hi all,
    I am using SStab control from the Microsfot tabbed controls. In my tab i
have 3 tabs. I have some controls in first tab. When I click tab 3  , some
validation has to happen with controls in the first tab. That is happening
when i click 3rd tab. But before the validation is over with success , the
3rd tab content should not be visible. If the validation fails the active
tab should not happen for the clicked tab. But what happening is when i
click 3rd tab, the 3rd tabs become active tab, then the click event of tab
is happening which is containing the validation code.

Is it possible to change this behaviour.

Thanks in advance for any help.....

-Regards
Santhakumar B



Tue, 19 Apr 2005 15:22:50 GMT  
 SStab control tab click , activating tab
If you drop an SSTab on a form, drop Text1 and Text2 on Tab 0 and any number
of controls on any other tab, paste the following code... and.... make sure
the tab controls CausesValidation property = True, you'll see that the tab
doesn't even attempt to change if Cancel = True (below)
'==========
Option Explicit

Private Sub Text1_Validate(Cancel As Boolean)
   If Text1.Text <> "Text1" Then
      Cancel = True
   End If
End Sub

Private Sub Text2_Validate(Cancel As Boolean)
   If Text2.Text <> "Text2" Then
      Cancel = True
   End If
End Sub
'==========

--
Ken Halter - MS-MVP-VB - Please keep it in the groups..
http://www.vbsight.com - http://www.vbsight.com/MultiColumn.htm
http://www.vbsight.com/TBGDialogCTL.htm


Quote:
> Hi all,
>     I am using SStab control from the Microsfot tabbed controls. In
> my tab i have 3 tabs. I have some controls in first tab. When I click
> tab 3  , some validation has to happen with controls in the first
> tab. That is happening when i click 3rd tab. But before the
> validation is over with success , the 3rd tab content should not be
> visible. If the validation fails the active tab should not happen for
> the clicked tab. But what happening is when i click 3rd tab, the 3rd
> tabs become active tab, then the click event of tab is happening
> which is containing the validation code.

> Is it possible to change this behaviour.

> Thanks in advance for any help.....

> -Regards
> Santhakumar B



Tue, 19 Apr 2005 23:16:47 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. Tabbed Dialog control (SSTab) with no tabs?

2. DragDrop from tab to tab in SSTab control?

3. sstab - move a frame on Tab x to Tab y at run time

4. How to activate Tabstrip tab WITHOUT clicking on it

5. Trapping tab change event before click n SSTAB

6. SSTabs,which tab received click

7. Determine which tab a control is on on an SSTab control

8. SSTab Control - Placing dinamically controls on tabs

9. SSTab Control problem-vb 4.0 (controls doesnt appear except on one tab )

10. VB432 SSTab Control copy controls between tabs

11. Masked Edit COM control appears only on first tab page of tab control in VB.NET

12. Tabbing through controls on a tab control

 

 
Powered by phpBB® Forum Software