Table of content 2 B4X Cross-platform projects
1 B4X platforms .............................................................................................................................. 4
2 First steps ..................................................................................................................................... 5
2.1 AdditionalLibraries folder structure ..................................................................................... 6
3 B4XPages ..................................................................................................................................... 8
3.1 What exactly does it solve? .................................................................................................. 8
3.2 What is a B4XPage?............................................................................................................. 9
3.3 New cross-platform B4XPages project .............................................................................. 10
3.4 B4XPages project structure ................................................................................................ 13
3.5 Code templates ................................................................................................................... 14
3.6 B4XMainPage Code template ............................................................................................ 15
3.6.1 B4XPage events ............................................................................................................. 16
3.6.1.1 B4XPage_CloseRequest ........................................................................................ 17
3.6.2 B4XPage methods .......................................................................................................... 18
3.6.3 Launch the IDE of another platform .............................................................................. 19
3.6.4 Generate a zip file for the project ................................................................................... 19
4 Compatibilities B4A B4i B4J XUI ........................................................................................ 20
5 Copy layouts, move views ......................................................................................................... 21
5.1 Copy layouts ...................................................................................................................... 21
5.2 Move views between pages ................................................................................................ 22
6 Access objects from another Page.............................................................................................. 23
7 B4X Templates........................................................................................................................... 24
8 Project with 2 pages B4XPagesTwoPages ................................................................................. 27
8.1 Steps to follow ................................................................................................................... 28
8.2 Setup of a project ............................................................................................................... 30
8.3 Modify the Package name in Build Configurations ........................................................... 31
8.4 Add a new B4XPage to the project .................................................................................... 31
8.4.1 Code of B4XMainPage .................................................................................................. 33
8.4.2 Code of B4XPage1 ......................................................................................................... 35
8.5 Create a B4XPages project zip file .................................................................................... 37
9 B4XPages version of the SecondProgram project ..................................................................... 38
9.1 Project structure ................................................................................................................. 38
9.2 B4J code adaptation ........................................................................................................... 41
9.3 B4A adaptation................................................................................................................... 43
9.4 B4i adaptation .................................................................................................................... 43
9.5 Conclusion ......................................................................................................................... 43
10 B4XPages Navigation through pages and program flow ........................................................... 44
11 B4XPagesNavBar ...................................................................................................................... 45
12 Other projects in the forum ........................................................................................................ 47