Jack Cole Well-Known Member Licensed User Longtime User Jul 16, 2022 #1 It would be nice to be able to reference variables from Globals/Process_Globals easily. One way to do it would be similar to how custom types are referenced. Here is what I imagine. Code: Copy Sub Process_Globals Dim SomeVariable as String End Sub Sub Globals Dim SomeImageView as ImageView End Sub Sub Activity_Create(FirstTime as Boolean) Vars.Globals.SomeImageView.Initialize("") Vars.Process_Globals.SomeString = "Test" End Sub Maybe it would be better to not split up Globals and Process_Globals for cross platform compatibility between B4A and B4i.
It would be nice to be able to reference variables from Globals/Process_Globals easily. One way to do it would be similar to how custom types are referenced. Here is what I imagine. Code: Copy Sub Process_Globals Dim SomeVariable as String End Sub Sub Globals Dim SomeImageView as ImageView End Sub Sub Activity_Create(FirstTime as Boolean) Vars.Globals.SomeImageView.Initialize("") Vars.Process_Globals.SomeString = "Test" End Sub Maybe it would be better to not split up Globals and Process_Globals for cross platform compatibility between B4A and B4i.
Erel B4X founder Staff member Licensed User Longtime User Jul 17, 2022 #2 Jack Cole said: Maybe it would be better to not split up Globals and Process_Globals for cross platform compatibility between B4A and B4i Click to expand... There are important differences between Globals and Process_Globals. Best thing to do with both of them is to never use them and switch to B4XPages. Simpler and cross platform.
Jack Cole said: Maybe it would be better to not split up Globals and Process_Globals for cross platform compatibility between B4A and B4i Click to expand... There are important differences between Globals and Process_Globals. Best thing to do with both of them is to never use them and switch to B4XPages. Simpler and cross platform.
Jack Cole Well-Known Member Licensed User Longtime User Jul 17, 2022 #3 Erel said: There are important differences between Globals and Process_Globals. Best thing to do with both of them is to never use them and switch to B4XPages. Simpler and cross platform. Click to expand... I use both. It is not practical to port my largest project from the cross platform system I developed that simulates the activity lifecycle on b4i.
Erel said: There are important differences between Globals and Process_Globals. Best thing to do with both of them is to never use them and switch to B4XPages. Simpler and cross platform. Click to expand... I use both. It is not practical to port my largest project from the cross platform system I developed that simulates the activity lifecycle on b4i.
Cableguy Expert Licensed User Longtime User Jul 17, 2022 #4 Jack Cole said: I use both. It is not practical to port my largest project from the cross platform system I developed that simulates the activity lifecycle on b4i. Click to expand... So you turned an I....phone into an android smartphone??? Don't let them know that!!!!
Jack Cole said: I use both. It is not practical to port my largest project from the cross platform system I developed that simulates the activity lifecycle on b4i. Click to expand... So you turned an I....phone into an android smartphone??? Don't let them know that!!!!
Jack Cole Well-Known Member Licensed User Longtime User Jul 17, 2022 #5 Cableguy said: So you turned an I....phone into an android smartphone??? Don't let them know that!!!! Click to expand... Yes, it is kind of true. And it works quite well.
Cableguy said: So you turned an I....phone into an android smartphone??? Don't let them know that!!!! Click to expand... Yes, it is kind of true. And it works quite well.