Hello,
Welcome to our Microsoft Q&A platform!
Xamarin.Forms.Shell
redefine the BackgroundColorProperty property. It's usage seems to be different with the property of VisualElement.
Shell
provides Shell.SetBackgroundColor method to set the backgroud color. Please remember to remove the line code if you've set a value for Shell.BackgroundColo
property in AppShell.xaml.
public partial class App : Application
{
public App()
{
InitializeComponent();
AppShell appShell = new AppShell();
Shell.SetBackgroundColor(appShell, Color.Red);
MainPage = appShell;
}
}
Check the links:
https://github.com/xamarin/Xamarin.Forms/blob/d7d5e01a7435f2fd055485959df8708c03911f67/Xamarin.Forms.Core/Shell/Shell.cs#L132
https://github.com/xamarin/Xamarin.Forms/blob/d7d5e01a7435f2fd055485959df8708c03911f67/Xamarin.Forms.Core/Shell/Shell.cs#L185
Best Regards,
Jarvan Zhang
If the response is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.