I am using the tabhost feature to navigate around my app. It took me a bit to figure it out but I managed. Now the problem question I have is that on my initial Page I want to make a label and button visiable or not based on a status flag. I am not having any success. I created the label and button using the designer and then using the program to modify it. Here is the code. Please help if you can. I just know it is going to be something simple and I will feel like an idiot. Thanks in advance for the help.
B4X:
Sub tbhPages_TabChanged
'everytime the tab is changed this event will be called.
Select tbhPages.CurrentTab
Case 0:
' ok we need to indicate that we are responding or away etc on the main page.
Select status
Case "Available":
myRespButt.Visible = False
myStatus.Text = "RESPONDING"
myStatus.Visible = True
Case "Away":
myRespButt.Visible = True
myStatus.Text = "Away"
myStatus.Visible = True
Case "Not Online":
myRespButt.Visible = False
myStatus.Text = "OFF Line"
myStatus.Visible = True
End Select
Case 1:
Log ("Away")
Case 2:
Log ("Register")
myRank.AddAll(Array As String("Chief", "Deputy", "Captain", "Lieutenant", "Fire Fighter", "Rookie"))
End Select
End Sub