Forum Xamarin Xamarin.Forms

ContentPage Frame HeightRequest not setting

AlbertKAlbertK MYMember ✭✭✭✭

I am on Xamarin Forms 3.3 deploying to Android 5.0 API 21 and it seems that I cannot set the HeightRequest of the Frame on the content page. I have changed the Frame to StackLayout (this gives me a shorter layout but still no able to set the heightrequest). Where is my mistake? Thank you.

<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns=""
             x:Name="Page4ContentPage" >

        <StackLayout Orientation="Horizontal" 
                     VerticalOptions="Center" Spacing="10" >
            <Label Text="Password"  TextColor="White" FontSize="24"  VerticalTextAlignment="Center" />

        <Frame x:Name="Page4Frame" Padding="0,0,0,0"  HeightRequest="400">
            <FlexLayout x:Name="Page4FlexLayout" Direction="Column" AlignItems="Center" JustifyContent="SpaceEvenly" >
                <StackLayout Padding="10,20,10,50" >
                    <Label Text="Please key a secure password" FontSize="24"/>

                <StackLayout Padding="10,0,10,20" Spacing="15" >
                    <Entry x:Name="Password" Focused="OnPasswordFocused" FontSize="Large" Placeholder="Password" IsPassword="True" MaxLength="64"/>
                    <Entry x:Name="Password2" FontSize="Large" Placeholder="Repeat Password" IsPassword="True" MaxLength="64" />
                <Button Text="Done"  x:Name="Page4Done" 
                        WidthRequest="120"  BorderRadius="60" VerticalOptions="Center" 
                        StyleClass="primary" HorizontalOptions="Center"
                        Clicked="OnButtonClicked" />


Best Answer


Sign In or Register to comment.