X xode Member Licensed User Mar 3, 2016 #1 Another noob question, In the wysiwyg designer I created a layout called main, matched connected device and then added a scrollview, a panel and 2 buttons the buttons are at either end of the panel (see picture attached). Then for code I have Activity.LoadLayout("main") Panel1.RemoveView ScrollView1.Panel1.AddView( Panel1, 0, 0, ScrollView1.Width, ScrollView1.Panel.Height ) I expect to be able to scroll the two buttons up and down the display. What I get is a white rectangle about 1/2 the size of the physical screen (a 7" Tab) and button1. The other button2 is nowhere to be seen and neither can I scroll it into view? Any ideas? http://imageshack.com/a/img924/3578/ZtAKBj.jpg Last edited: Mar 3, 2016
Another noob question, In the wysiwyg designer I created a layout called main, matched connected device and then added a scrollview, a panel and 2 buttons the buttons are at either end of the panel (see picture attached). Then for code I have Activity.LoadLayout("main") Panel1.RemoveView ScrollView1.Panel1.AddView( Panel1, 0, 0, ScrollView1.Width, ScrollView1.Panel.Height ) I expect to be able to scroll the two buttons up and down the display. What I get is a white rectangle about 1/2 the size of the physical screen (a 7" Tab) and button1. The other button2 is nowhere to be seen and neither can I scroll it into view? Any ideas? http://imageshack.com/a/img924/3578/ZtAKBj.jpg
Erel B4X founder Staff member Licensed User Longtime User Mar 3, 2016 #2 What is the value of Inner Height property set to (of the scrollbar)? Upvote 0
X xode Member Licensed User Mar 3, 2016 #3 Erel said: What is the value of Inner Height property set to (of the scrollbar)? Click to expand... Hi, In the Designer window properties box for ScrollView I see "ScrollView Properties" and "Inner Height = 500" Thx Upvote 0
Erel said: What is the value of Inner Height property set to (of the scrollbar)? Click to expand... Hi, In the Designer window properties box for ScrollView I see "ScrollView Properties" and "Inner Height = 500" Thx
Erel B4X founder Staff member Licensed User Longtime User Mar 3, 2016 #4 Can you upload your project (File - Export as zip)? Upvote 0
X xode Member Licensed User Mar 3, 2016 #5 Hi, Project as requested https://www.dropbox.com/s/li6r4w9zdkkda4g/testsv2.zip?dl=0 Thx Upvote 0
Erel B4X founder Staff member Licensed User Longtime User Mar 4, 2016 #6 The main layout should include the ScrollView. It should be anchored to all sizes: The inner height should be set to 1200. The second layout should include the panel. Its height should be set to 1200. Disable AutoScaleAll for this layout. The code: Code: Copy Sub Activity_Create(FirstTime As Boolean) 'Do not forget to load the layout file created with the visual designer. For example: Activity.LoadLayout("main") ScrollView1.Panel.LoadLayout("2") End Sub Upvote 0
The main layout should include the ScrollView. It should be anchored to all sizes: The inner height should be set to 1200. The second layout should include the panel. Its height should be set to 1200. Disable AutoScaleAll for this layout. The code: Code: Copy Sub Activity_Create(FirstTime As Boolean) 'Do not forget to load the layout file created with the visual designer. For example: Activity.LoadLayout("main") ScrollView1.Panel.LoadLayout("2") End Sub