Android Question [B4XPages] About B4XPages.GlobalContext

vfafou

Well-Known Member
Licensed User
Longtime User
Hello!
I would like to ask the following questions:
According to this post: https://www.b4x.com/android/forum/threads/b4xpages-shared-constants.121269/ we can access globals from any B4XPages app modules. If we write:
B4X:
Sub Process_Globals
    
End Sub

Sub Service_Create
    Public AppGlobals As clsGlobals
    AppGlobals.Initialize
    B4XPages.GlobalContext = AppGlobals
End Sub
then we don't have access from other modules. it may be:
B4X:
Sub Process_Globals
    Public AppGlobals As clsGlobals
End Sub

Sub Service_Create
    
    AppGlobals.Initialize
    B4XPages.GlobalContext = AppGlobals
End Sub
If this is not right, how do we access the AppGlobals from any other modules?

Thank you in advance.
 
Top