F fishwolf Well-Known Member Licensed User Longtime User Dec 11, 2014 #1 I have try to create a new module and the app start with a blank page. why? Attachments MoreModules.zip MoreModules.zip 11.1 KB · Views: 456
Erel B4X founder Staff member Licensed User Longtime User Dec 11, 2014 #2 This line is wrong: Code: Copy NavControl.ShowPage(Main) You need to show a page, not a code module. Upvote 0
F fishwolf Well-Known Member Licensed User Longtime User Dec 12, 2014 #3 Erel said: This line is wrong: Code: Copy NavControl.ShowPage(Main) You need to show a page, not a code module. Click to expand... i don't understand, i have see this thread https://www.b4x.com/android/forum/threads/working-with-multiple-app-pages.45943/ how should I do? Upvote 0
Erel said: This line is wrong: Code: Copy NavControl.ShowPage(Main) You need to show a page, not a code module. Click to expand... i don't understand, i have see this thread https://www.b4x.com/android/forum/threads/working-with-multiple-app-pages.45943/ how should I do?
Erel B4X founder Staff member Licensed User Longtime User Dec 12, 2014 #4 Don't confuse Pages with modules. A Page is an object like all other objects (Button, String, etc...). You need to pass a page to NavControl.ShowPage. Main is a module not a page. Upvote 0
Don't confuse Pages with modules. A Page is an object like all other objects (Button, String, etc...). You need to pass a page to NavControl.ShowPage. Main is a module not a page.
F fishwolf Well-Known Member Licensed User Longtime User Dec 13, 2014 #5 "Main" is a module (files) and a page, the same name i have change name to page and work fine. maybe it's a bug Last edited: Dec 13, 2014 Upvote 0
"Main" is a module (files) and a page, the same name i have change name to page and work fine. maybe it's a bug
klaus Expert Licensed User Longtime User Dec 13, 2014 #6 No it's not a bug ! As Erel already told you ! Don't confuse Modules and pages. In the Main module you can handle several pages ! Look at chapter 12 User Interfaces in the B4i Beginner's Guide. Last edited: Dec 14, 2014 Upvote 0
No it's not a bug ! As Erel already told you ! Don't confuse Modules and pages. In the Main module you can handle several pages ! Look at chapter 12 User Interfaces in the B4i Beginner's Guide.
F fishwolf Well-Known Member Licensed User Longtime User Dec 14, 2014 #7 Ok, i have resolved changed the name to page Other question: now i have 2 modules (files), i must capture the events of page2 text on page2 module, work only if i write into main module. Maybe i must change the parent, how to ? Code: Copy work fine Main Sub TextEmail_EnterPressed Msgbox ("Main TextEmail EnterPressed", "Debug") End Sub doesn't work Page2 Sub TextEmail_EnterPressed Msgbox ("Page2 TextEmail EnterPressed", "Debug") End Sub Attachments MoreModules.zip MoreModules.zip 5.7 KB · Views: 442 Last edited: Dec 14, 2014 Upvote 0
Ok, i have resolved changed the name to page Other question: now i have 2 modules (files), i must capture the events of page2 text on page2 module, work only if i write into main module. Maybe i must change the parent, how to ? Code: Copy work fine Main Sub TextEmail_EnterPressed Msgbox ("Main TextEmail EnterPressed", "Debug") End Sub doesn't work Page2 Sub TextEmail_EnterPressed Msgbox ("Page2 TextEmail EnterPressed", "Debug") End Sub
Erel B4X founder Staff member Licensed User Longtime User Dec 14, 2014 #8 Have you seen this example: Multiple Pages Example ? Upvote 0
F fishwolf Well-Known Member Licensed User Longtime User Dec 15, 2014 #9 Thanks, now it's all clear. Upvote 0