Dim currentRoute As Map
currentRoute = DBUtils.ExecuteMap(SQLLite, "SELECT srt_approved, srt_mustrefresh, srt_refreshed FROM SelectedRoute", Null)
If currentRoute.IsInitialized Then
approved = currentRoute.Get("srt_approved")
Dim mustRefresh As Object
mustRefresh = currentRoute.Get("srt_mustrefresh")
Dim refreshed As Object
refreshed = currentRoute.Get("srt_refreshed")
If approved = 0 Then
TabManager.setTabEnabled2(tbhMain, True, 1) ' load awbs
TabManager.setTabEnabled2(tbhMain, True, 2) ' approve run sheet
TabManager.setTabEnabled2(tbhMain, False, 3) ' deliver awbs
TabManager.setTabEnabled2(tbhMain, False, 4) ' upload to server
Else
If (mustRefresh = 0) Then
TabManager.setTabEnabled2(tbhMain, False, 1) ' load awbs
TabManager.setTabEnabled2(tbhMain, False, 2) ' approve run sheet
TabManager.setTabEnabled2(tbhMain, True, 3) ' deliver awbs
TabManager.setTabEnabled2(tbhMain, True, 4) ' upload to server
End If
If (mustRefresh = 1 AND refreshed = 0) Then
.
.
.