我刚开始了一个Xamarin.Forms应用程序,我想为我的XAML添加背景图片。 我添加了属性,但它在运行时不会显示! 这是图像。Xamarin.Forms Xaml背景图片
APP
public class App : Application
{
public App()
{
// The root page of your application
MainPage = new Page();
}
XAML:
<ContentPage xmlns="http://xamarin.com/schemas/2014/forms"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="App1.Page"
BackgroundImage="bg.png">
那么,该如何解决呢?
你好SushiHangover, 我只是这样做,静静的,没有出现= X – Biellx
@Biellx我加了一些信息,以我的回答,请确保该图像是在正确的文件夹,并指派了正确生成操作。清理并重建并重新部署到您的设备/仿真程序... – SushiHangover
Yeaa,我认为问题是构建操作,我如何将构建操作设置为该图像?] – Biellx