This repository has been archived by the owner on May 1, 2024. It is now read-only.
ScrollView with Expander staying in view #1406
-
I have a menu in a ScrollView made up of Expanders. Can someone point me to a way to make sure that when the expander is expanded by the user if it is outside of the scroll area it gets scrolled into view? I did find a stack overflow posting, but it was Windows wpf specific and references things that don't seem to existin Xamarin iOS / Android. |
Beta Was this translation helpful? Give feedback.
Answered by
AndreiMisiukevich
Jun 16, 2021
Replies: 1 comment 3 replies
-
@tpitman you always can scroll on your own :) var exp = new Expander();
var scr = new ScrollView();
exp.PropertyChanged += (s, e) =>
{
if (e.PropertyName == Expander.StateProperty.PropertyName && exp.State == ExpandState.Expanded)
{
scr.ScrollToAsync(exp, ScrollToPosition.MakeVisible, true);
}
}; |
Beta Was this translation helpful? Give feedback.
3 replies
Answer selected by
tpitman
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
@tpitman you always can scroll on your own :)