Android Question TabHost - Enable / Disable a single TabHost.Tab

GMan

Well-Known Member
Licensed User
Longtime User
I want to make a tab(1) of a tabhost only visible, if the scrollview of the previous tab(0) has reached nearly 100%.
I use this code:
B4X:
Sub InfosSV_ScrollChanged (Position As Int)
If InfosSV.ScrollPosition  > 6050 Then
    Msgbox("Reached","6050")
    ' TabHost1.???????.Enabled = True
End If
End Sub


So, the MsgBox appears an the end of the SV, but how can i disable / enable a (previous disabled) Tab(1) of the TabHost ?
 

mangojack

Well-Known Member
Licensed User
Longtime User
download TabHostExtras library .. (see above ,similar threads)

then ...
B4X:
Dim TabExtras as TabHostExtras

TabExtras.setTabEnabled2(TabHost1,False,2)

Explore the TabHostExtras other methods as well .. TabColours, TabVisible etc ....
 
Last edited:
Upvote 0

GMan

Well-Known Member
Licensed User
Longtime User
Muchas Gracias - that's it.
Nice Lib - only EXPANDS the existing one :D
 
Upvote 0
Top