Hi,
I am using the iSideMenu with a iTabStrip and trying to use a scrollview in one of the tabs but can't work out why the layout isn't loading in the scrollview.
I have attached my test project.
Any ideas on where I have gone wrong ?
Main:
MyPage2:
I am using the iSideMenu with a iTabStrip and trying to use a scrollview in one of the tabs but can't work out why the layout isn't loading in the scrollview.
I have attached my test project.
Any ideas on where I have gone wrong ?
Main:
B4X:
Sub Process_Globals
'These global variables will be declared once when the application starts.
'Public variables can be accessed from all modules.
Public App As Application
Public NavControl As NavigationController
Private Page1 As Page
Public smc As SideMenuController 'iSideMenu Lib
End Sub
Private Sub Application_Start (Nav As NavigationController)
'SetDebugAutoFlushLogs(True) 'Uncomment if program crashes before all logs are printed.
NavControl = Nav
NavControl.Initialize("")
Dim lp As Page
lp.Initialize("lp")
lp.RootPanel.Color = Colors.Red
lp.RootPanel.LoadLayout("LeftMenu")
smc.Initialize(lp, NavControl, Null)
smc.OpenGesturesEnabled = False
App.KeyController = smc
NavControl.NavigationBarVisible = False
MyPage2.show(NavControl) ' this will show the login screen
End Sub
MyPage2:
B4X:
Sub Process_Globals
'These global variables will be declared once when the application starts.
'Public variables can be accessed from all modules.
Private MainPage As Page
Private TabStripPanel As Panel
Private TabPages As List
Private TabPage1, TabPage2, TabPage3 As Page
Private TabStrip1 As TabStrip
Private ScrollView1 As ScrollView
End Sub
Public Sub Show(Parent As NavigationController)
If MainPage.IsInitialized = False Then
' Main Page
MainPage.Initialize("MainPage")
MainPage.Title = "Page 1"
MainPage.RootPanel.Color = Colors.White
MainPage.RootPanel.LoadLayout("Main")
End If
Parent.ShowPage(MainPage)
TabStripPanel.LoadLayout("TabStripLayoutOnly")
TabPages.Initialize
TabPage1.Initialize("TabPage1")
TabPage1.RootPanel.LoadLayout("Tab1Layout")
TabPage1.Title = "1"
TabPages.Add(TabPage1)
TabPage2.Initialize("TabPage2")
TabPage2.RootPanel.LoadLayout("Tab2Layout")
TabPage2.Title = "2"
TabPages.Add(TabPage2)
TabPage3.Initialize("TabPage3")
TabPage3.RootPanel.LoadLayout("ScrollViewLayout")
ScrollView1.Panel.LoadLayout("Tab3Layout")
TabPage3.Title = "3"
TabPages.Add(TabPage3)
TabStrip1.SetPages(TabPages)
End Sub