Xamarin.Forms scrolls only part of the page

I have a page where I want to have a title that always appears at the top, and buttons that always appear at the bottom. contents in the middle scroll.

I thought this would be easy to do by doing the following:

StackLayout outer = new StackLayout(); StackLayout inner = new StackLayout();//with all of the content added ScrollView scroll = new ScrollView(); outer.Children.Add(headerLabel);//non-scrolling scroll.Content = inner; outer.Children.Add(scroll); //scrolling outer.Children.Add(button); //non-scrolling 

The headerLabel key and the button remain in their original position, but the contents scroll to the top of the page at the top of the title bar (but below / below the button below).

I am sure that it worked correctly, but I can’t change anything.

Does anyone have any ideas on why this is happening?

+5
source share
1 answer

so that fixed him

 outer.VerticalOptions = LayoutOptions.End; 

and

 scroll.IsClippedToBounds=true; 
+5
source

Source: https://habr.com/ru/post/1204041/


All Articles