M mackrackit Member Licensed User Longtime User May 9, 2019 #1 Hi, I am trying to figure out how to place an animated compass on a scrollview. The compass works and I have three scrollviews working, but the compass is covering all three views. How do I put the compass on one view? Thanks for any help! Attachments MultiplePanels.zip MultiplePanels.zip 32.5 KB · Views: 546 Screenshot_20190508-173004.jpg 10 KB · Views: 1,325 Last edited: May 9, 2019
Hi, I am trying to figure out how to place an animated compass on a scrollview. The compass works and I have three scrollviews working, but the compass is covering all three views. How do I put the compass on one view? Thanks for any help!
Erel B4X founder Staff member Licensed User Longtime User May 9, 2019 #2 It is a mistake to upload large screenshots. It makes the post unreadable. 1. This is not needed: Code: Copy Sub Activity_Create(FirstTime As Boolean) For i = Activity.NumberOfViews - 1 To 0 Step -1 Activity.RemoveViewAt(i) Next The activity will always start with no views. mackrackit said: How do I put the compass on one view? Click to expand... Add it to a panel that belongs to one of the tabs (Panel1). I recommend you to use TabStripViewPager. Looks and behaves better than TabHost. Upvote 0
It is a mistake to upload large screenshots. It makes the post unreadable. 1. This is not needed: Code: Copy Sub Activity_Create(FirstTime As Boolean) For i = Activity.NumberOfViews - 1 To 0 Step -1 Activity.RemoveViewAt(i) Next The activity will always start with no views. mackrackit said: How do I put the compass on one view? Click to expand... Add it to a panel that belongs to one of the tabs (Panel1). I recommend you to use TabStripViewPager. Looks and behaves better than TabHost.
M mackrackit Member Licensed User Longtime User May 9, 2019 #3 Hi Erel, I scaled the screenshot down, sorry. Removed the section you suggested, thank you for the tip. But, I still do not know how to add the compass to the Panel in code. Will look at TabStripViewPager. Thank you! Upvote 0
Hi Erel, I scaled the screenshot down, sorry. Removed the section you suggested, thank you for the tip. But, I still do not know how to add the compass to the Panel in code. Will look at TabStripViewPager. Thank you!
Erel B4X founder Staff member Licensed User Longtime User May 10, 2019 #4 You need to replace: Code: Copy Activity.AddView(CompassImageView, ...) 'with: Panel1.AddView(CompassImageView, ...) Upvote 0
You need to replace: Code: Copy Activity.AddView(CompassImageView, ...) 'with: Panel1.AddView(CompassImageView, ...)
M mackrackit Member Licensed User Longtime User May 10, 2019 #5 Thank you Erel !! I was so fixed on "Sub Activity_Create(FirstTime As Boolean)" getting the ScrollViews and Panels working that I got it in my head that the call to EditMode sub had to be made from "Activity_Create". Upvote 0
Thank you Erel !! I was so fixed on "Sub Activity_Create(FirstTime As Boolean)" getting the ScrollViews and Panels working that I got it in my head that the call to EditMode sub had to be made from "Activity_Create".