B4J Question [ABMaterial] Error 403: The requested resource requires authentication

micro

Well-Known Member
Licensed User
Longtime User
Hi to all
In NavigatioBar i have a icon "Contact", after the login on the ABMApplication page i load the Home page.
In this page in the sub Page_NavigationbarClicked i have this code:
B4X:
Sub Page_NavigationbarClicked(Action As String, Value As String)

    ' saving the navigation bar position
    page.SaveNavigationBarPosition
    If Action = "LogOff" Then
        ABMShared.LogOff(page)
        Return
    End If
    Select Action
        Case "Contact"
            ShowMessage("Licenza: " & ws.Session.GetAttribute("licenza"), "Info Utente-Licenza")
    End Select
    ABMShared.NavigateToPage(ws, ABMPageId, Value)
End Sub
if I click on the Contact icon the MsgBox is displayed for a short time, after the server disconnects and appears:
B4X:
Error 403: The requested resource requires authentication.


You can go back to the homepage by clicking here!

If i comment this line:
B4X:
'ABMShared.NavigateToPage(ws, ABMPageId, Value)
work well.

what am I doing wrong?

P.S.
In ABMapplication page after then correct login i set this:
B4X:
ws.Session.SetAttribute("IsAuthorized", "true")
 

Harris

Expert
Licensed User
Longtime User
What is the value of "Value"? Where is it trying to navigate to?
 
Upvote 0

Harris

Expert
Licensed User
Longtime User
ShowMessage("Licenza: " & ws.Session.GetAttribute("licenza"), "Info Utente-Licenza")
Return

Use return after showmessage - so you don't try and navigate anywhere.....
 
Upvote 0
Top