Android Question Size scrollview

Hirogens

Active Member
Licensed User
Longtime User
Hello, I was thinking that I had fixed my problem but I was wrong

I would like to create a scrollview with a good size with all smartphones. Actually my problem is when I try to finish my scroll view with a picture but with some smartphones it's cut.
I use that
B4X:
scrollview_sante.Panel.Height = panel_sante.Height
How can I fix that ?
Thanks
 

stevel05

Expert
Licensed User
Longtime User
You should check for errors in the top of the IDE Logs pane, you have initialized panel_sante in code which is added with the designer, this is wrong and will cause problems.

See if that cures this problem.
 
Last edited:
Upvote 0

Hirogens

Active Member
Licensed User
Longtime User
You need to set the panel height to the last view's top+height plus maybe some space behind it.
B4X:
scrollview_sante.panel.height = last_view.top + last_view.Height
I load my panel with pictures on my scrollview so last_view is the background where my scroll view is ?
 
Upvote 0

klaus

Expert
Licensed User
Longtime User
You should remove: panel_sante.Initialize("sante")
Then, in the Designer, you should set the vertical anchor of panel_sante and img_body to Top
upload_2018-7-19_12-16-15.png
and not to both
upload_2018-7-19_12-16-28.png
!
This line scrollview_sante.Panel.Height = panel_sante.Height is OK!

Attached a modified project.
 

Attachments

  • sw_issue_new.zip
    185.6 KB · Views: 275
Upvote 0
Top