B4J Question [B4XPages] how to call sub in 3rd page ?

peacemaker

Expert
Licensed User
Longtime User
Hi, All

Do we have full example how to call subs in pages ? Without it it's impossible to work.
Each class is inited in some one module, and ... how to update this class, if impossible to call it from some other code module or page?
Say, update screen list. MainPage can be updated, yes, but .... why other pages, if no possibility...
 
Does this look right for you?
B4X: Copy
CallSub (Component As Object, Sub As String) As Object
CallSub2 (Component As Object, Sub As String, Argument As Object) As Object
CallSub3 (Component As Object, Sub As String, Argument1 As Object, Argument2 As Object) As Object
 
Upvote 0
Yes, Component looks like a B4XPages.GetPage("PageID").
Solved, thanks :)
 
Upvote 0
Maybe there is another way??
Assuming functions that use pag1...page1 needs to be public,

you can try
B4X: Copy
Page1.Fun1
 
Upvote 0
Back
Top