The use case is with cross platform apps that can start in the background. For example after they receive a push notification. In that case B4XPages will not be initialized but B4XPages.GlobalContext will still be available (if assigned properly when the app starts, in the starter service in B4A).
B4X:
Sub Message_Received
Starter.SQL.DoSomething 'not cross platform
Dim sql As SQL = B4XPages.GlobalContext 'cross platform
sql.DoSomething
In fact that page talks about B4XPages.B4XGlobalContext not B4XPages.GlobalContext.
I note also it talks about initializing it in Service_Create of the starter service, but in fact B4XPages.GlobalContext can hold standard variables with being initialized.
I note also it talks about initializing it in Service_Create of the starter service, but in fact B4XPages.GlobalContext can hold standard variables with being initialized.
That's true. It can hold whatever you like. It does make sense to initialize that object in Service_Create of the starter service. This way it will be available in all cases.