How can I set the background color of a frame in XAML?

Platform: .NET MAUI| Category: General

You can set the background color of a frame using the BackgroundColor property:

XAML

<Frame CornerRadius="5" BorderColor="Black" 
                        	  HasShadow="True" 
                            HeightRequest="200" 
				  BackgroundColor="Gray"                         
                            WidthRequest="200">        
            <Label Text="Frame wrapped around a Label" />       
</Frame>

Share with

Related FAQs

Couldn't find the FAQs you're looking for?

Please submit your question and answer.