Hi there,
After broadening my POC app, I now have almost 10 activities, and supporting code modules to control them - this covers off some of the prototyping of screen flow, however now to start sharing objects and classes.
I was hoping to declare a global central class to store some information about the local device/user (), however can't get globals to be seen in other activities.
Basic architecture is code module "Main"
I can't seem to get the variable APP_NAME to be viewable in another activity. and do not close the "Main" activity.
I realise this might be due to scoping, however want to be able to share variables across modules without having to directly cast it to the next suite of modules.
I also realise that I'm almost certain it's because I'm just missing something *really* simple :-\
After broadening my POC app, I now have almost 10 activities, and supporting code modules to control them - this covers off some of the prototyping of screen flow, however now to start sharing objects and classes.
I was hoping to declare a global central class to store some information about the local device/user (), however can't get globals to be seen in other activities.
Basic architecture is code module "Main"
Sub Process_Globals
End Sub
Sub Globals
End Sub
Sub Activity_Create(FirstTime AsBoolean)
'These global variables will be declared once when the application starts.
'These variables can be accessed from all modules.
Dim APP_NAME = "My App Name" As String
'These variables can be accessed from all modules.
Dim APP_NAME = "My App Name" As String
End Sub
Sub Globals
'These global variables will be redeclared each time the activity is created.
'These variables can only be accessed from this module.
'These variables can only be accessed from this module.
End Sub
Sub Activity_Create(FirstTime AsBoolean)
'Do not forget to load the layout file created with the visual designer. For example:
StartActivity("modActLogin")
End SubStartActivity("modActLogin")
I can't seem to get the variable APP_NAME to be viewable in another activity. and do not close the "Main" activity.
I realise this might be due to scoping, however want to be able to share variables across modules without having to directly cast it to the next suite of modules.
I also realise that I'm almost certain it's because I'm just missing something *really* simple :-\