Как следует из названия, сборка проекта не удалась, было обнаружено 13 ошибок сборки. Я только что обновил Visual Studio 2022 и отметил все необходимые параметры. Создание нового проекта и его сборка немедленно завершаются сбоем.
Для получения дополнительной информации я запускаю его на компьютере под управлением Windows, который завершает работу с ошибкой net9.0-windows10.0.19041.0< /strong>.
Выдает следующие ошибки
1>C:\Users\115al\Documents\GitHub\5e-Monster-Randomiser-.NET-Maui-App\5e Randomiser\obj\Debug\net9.0-windows10.0.19041.0\win10-x64\intermediatexaml\WinRT.SourceGenerator\Generator.WinRTAotSourceGenerator\_5e_Randomiser.WinUI.App.WinRTVtable.g.cs(4,40,4,53): error CS0118: 'global::WinRT' is a namespace but is used like a type
1>C:\Users\115al\Documents\GitHub\5e-Monster-Randomiser-.NET-Maui-App\5e Randomiser\obj\Debug\net9.0-windows10.0.19041.0\win10-x64\intermediatexaml\WinRT.SourceGenerator\Generator.WinRTAotSourceGenerator\_5e_Randomiser.WinUI.App.WinRTVtable.g.cs(4,57,4,80): error CS0103: The name 'RandomiserVtableClasses' does not exist in the current context
1>C:\Users\115al\Documents\GitHub\5e-Monster-Randomiser-.NET-Maui-App\5e Randomiser\obj\Debug\net9.0-windows10.0.19041.0\win10-x64\intermediatexaml\WinRT.SourceGenerator\Generator.WinRTAotSourceGenerator\_5e_Randomiser.WinUI.App.WinRTVtable.g.cs(4,2,4,122): error CS1729: 'WinRTExposedTypeAttribute' does not contain a constructor that takes 3 arguments
1>C:\Users\115al\Documents\GitHub\5e-Monster-Randomiser-.NET-Maui-App\5e Randomiser\obj\Debug\net9.0-windows10.0.19041.0\win10-x64\intermediatexaml\WinRT.SourceGenerator\Generator.WinRTAotSourceGenerator\_5e_Randomiser.App.WinRTVtable.g.cs(4,40,4,53): error CS0118: 'global::WinRT' is a namespace but is used like a type
1>C:\Users\115al\Documents\GitHub\5e-Monster-Randomiser-.NET-Maui-App\5e Randomiser\obj\Debug\net9.0-windows10.0.19041.0\win10-x64\intermediatexaml\WinRT.SourceGenerator\Generator.WinRTAotSourceGenerator\_5e_Randomiser.App.WinRTVtable.g.cs(4,57,4,80): error CS0103: The name 'RandomiserVtableClasses' does not exist in the current context
1>C:\Users\115al\Documents\GitHub\5e-Monster-Randomiser-.NET-Maui-App\5e Randomiser\obj\Debug\net9.0-windows10.0.19041.0\win10-x64\intermediatexaml\WinRT.SourceGenerator\Generator.WinRTAotSourceGenerator\_5e_Randomiser.App.WinRTVtable.g.cs(4,2,4,121): error CS1729: 'WinRTExposedTypeAttribute' does not contain a constructor that takes 3 arguments
1>C:\Users\115al\Documents\GitHub\5e-Monster-Randomiser-.NET-Maui-App\5e Randomiser\obj\Debug\net9.0-windows10.0.19041.0\win10-x64\intermediatexaml\WinRT.SourceGenerator\Generator.WinRTAotSourceGenerator\_5e_Randomiser.MainPage.WinRTVtable.g.cs(4,40,4,53): error CS0118: 'global::WinRT' is a namespace but is used like a type
1>C:\Users\115al\Documents\GitHub\5e-Monster-Randomiser-.NET-Maui-App\5e Randomiser\obj\Debug\net9.0-windows10.0.19041.0\win10-x64\intermediatexaml\WinRT.SourceGenerator\Generator.WinRTAotSourceGenerator\_5e_Randomiser.MainPage.WinRTVtable.g.cs(4,57,4,80): error CS0103: The name 'RandomiserVtableClasses' does not exist in the current context
1>C:\Users\115al\Documents\GitHub\5e-Monster-Randomiser-.NET-Maui-App\5e Randomiser\obj\Debug\net9.0-windows10.0.19041.0\win10-x64\intermediatexaml\WinRT.SourceGenerator\Generator.WinRTAotSourceGenerator\_5e_Randomiser.MainPage.WinRTVtable.g.cs(4,2,4,121): error CS1729: 'WinRTExposedTypeAttribute' does not contain a constructor that takes 3 arguments
1>C:\Users\115al\Documents\GitHub\5e-Monster-Randomiser-.NET-Maui-App\5e Randomiser\obj\Debug\net9.0-windows10.0.19041.0\win10-x64\intermediatexaml\WinRT.SourceGenerator\Generator.WinRTAotSourceGenerator\_5e_Randomiser.AppShell.WinRTVtable.g.cs(4,40,4,53): error CS0118: 'global::WinRT' is a namespace but is used like a type
1>C:\Users\115al\Documents\GitHub\5e-Monster-Randomiser-.NET-Maui-App\5e Randomiser\obj\Debug\net9.0-windows10.0.19041.0\win10-x64\intermediatexaml\WinRT.SourceGenerator\Generator.WinRTAotSourceGenerator\_5e_Randomiser.AppShell.WinRTVtable.g.cs(4,57,4,80): error CS0103: The name 'RandomiserVtableClasses' does not exist in the current context
1>C:\Users\115al\Documents\GitHub\5e-Monster-Randomiser-.NET-Maui-App\5e Randomiser\obj\Debug\net9.0-windows10.0.19041.0\win10-x64\intermediatexaml\WinRT.SourceGenerator\Generator.WinRTAotSourceGenerator\_5e_Randomiser.AppShell.WinRTVtable.g.cs(4,2,4,121): error CS1729: 'WinRTExposedTypeAttribute' does not contain a constructor that takes 3 arguments
1>Done building project "5e Randomiser.csproj" -- FAILED.
Как следует из названия, сборка проекта не удалась, было обнаружено 13 ошибок сборки. Я только что обновил Visual Studio 2022 и отметил все необходимые параметры. Создание нового проекта и его сборка немедленно завершаются сбоем. Для получения дополнительной информации я запускаю его на компьютере под управлением Windows, который завершает работу с ошибкой net9.0-windows10.0.19041.0< /strong>. Выдает следующие ошибки [code]1>C:\Users\115al\Documents\GitHub\5e-Monster-Randomiser-.NET-Maui-App\5e Randomiser\obj\Debug\net9.0-windows10.0.19041.0\win10-x64\intermediatexaml\WinRT.SourceGenerator\Generator.WinRTAotSourceGenerator\_5e_Randomiser.WinUI.App.WinRTVtable.g.cs(4,40,4,53): error CS0118: 'global::WinRT' is a namespace but is used like a type 1>C:\Users\115al\Documents\GitHub\5e-Monster-Randomiser-.NET-Maui-App\5e Randomiser\obj\Debug\net9.0-windows10.0.19041.0\win10-x64\intermediatexaml\WinRT.SourceGenerator\Generator.WinRTAotSourceGenerator\_5e_Randomiser.WinUI.App.WinRTVtable.g.cs(4,57,4,80): error CS0103: The name 'RandomiserVtableClasses' does not exist in the current context 1>C:\Users\115al\Documents\GitHub\5e-Monster-Randomiser-.NET-Maui-App\5e Randomiser\obj\Debug\net9.0-windows10.0.19041.0\win10-x64\intermediatexaml\WinRT.SourceGenerator\Generator.WinRTAotSourceGenerator\_5e_Randomiser.WinUI.App.WinRTVtable.g.cs(4,2,4,122): error CS1729: 'WinRTExposedTypeAttribute' does not contain a constructor that takes 3 arguments 1>C:\Users\115al\Documents\GitHub\5e-Monster-Randomiser-.NET-Maui-App\5e Randomiser\obj\Debug\net9.0-windows10.0.19041.0\win10-x64\intermediatexaml\WinRT.SourceGenerator\Generator.WinRTAotSourceGenerator\_5e_Randomiser.App.WinRTVtable.g.cs(4,40,4,53): error CS0118: 'global::WinRT' is a namespace but is used like a type 1>C:\Users\115al\Documents\GitHub\5e-Monster-Randomiser-.NET-Maui-App\5e Randomiser\obj\Debug\net9.0-windows10.0.19041.0\win10-x64\intermediatexaml\WinRT.SourceGenerator\Generator.WinRTAotSourceGenerator\_5e_Randomiser.App.WinRTVtable.g.cs(4,57,4,80): error CS0103: The name 'RandomiserVtableClasses' does not exist in the current context 1>C:\Users\115al\Documents\GitHub\5e-Monster-Randomiser-.NET-Maui-App\5e Randomiser\obj\Debug\net9.0-windows10.0.19041.0\win10-x64\intermediatexaml\WinRT.SourceGenerator\Generator.WinRTAotSourceGenerator\_5e_Randomiser.App.WinRTVtable.g.cs(4,2,4,121): error CS1729: 'WinRTExposedTypeAttribute' does not contain a constructor that takes 3 arguments 1>C:\Users\115al\Documents\GitHub\5e-Monster-Randomiser-.NET-Maui-App\5e Randomiser\obj\Debug\net9.0-windows10.0.19041.0\win10-x64\intermediatexaml\WinRT.SourceGenerator\Generator.WinRTAotSourceGenerator\_5e_Randomiser.MainPage.WinRTVtable.g.cs(4,40,4,53): error CS0118: 'global::WinRT' is a namespace but is used like a type 1>C:\Users\115al\Documents\GitHub\5e-Monster-Randomiser-.NET-Maui-App\5e Randomiser\obj\Debug\net9.0-windows10.0.19041.0\win10-x64\intermediatexaml\WinRT.SourceGenerator\Generator.WinRTAotSourceGenerator\_5e_Randomiser.MainPage.WinRTVtable.g.cs(4,57,4,80): error CS0103: The name 'RandomiserVtableClasses' does not exist in the current context 1>C:\Users\115al\Documents\GitHub\5e-Monster-Randomiser-.NET-Maui-App\5e Randomiser\obj\Debug\net9.0-windows10.0.19041.0\win10-x64\intermediatexaml\WinRT.SourceGenerator\Generator.WinRTAotSourceGenerator\_5e_Randomiser.MainPage.WinRTVtable.g.cs(4,2,4,121): error CS1729: 'WinRTExposedTypeAttribute' does not contain a constructor that takes 3 arguments 1>C:\Users\115al\Documents\GitHub\5e-Monster-Randomiser-.NET-Maui-App\5e Randomiser\obj\Debug\net9.0-windows10.0.19041.0\win10-x64\intermediatexaml\WinRT.SourceGenerator\Generator.WinRTAotSourceGenerator\_5e_Randomiser.AppShell.WinRTVtable.g.cs(4,40,4,53): error CS0118: 'global::WinRT' is a namespace but is used like a type 1>C:\Users\115al\Documents\GitHub\5e-Monster-Randomiser-.NET-Maui-App\5e Randomiser\obj\Debug\net9.0-windows10.0.19041.0\win10-x64\intermediatexaml\WinRT.SourceGenerator\Generator.WinRTAotSourceGenerator\_5e_Randomiser.AppShell.WinRTVtable.g.cs(4,57,4,80): error CS0103: The name 'RandomiserVtableClasses' does not exist in the current context 1>C:\Users\115al\Documents\GitHub\5e-Monster-Randomiser-.NET-Maui-App\5e Randomiser\obj\Debug\net9.0-windows10.0.19041.0\win10-x64\intermediatexaml\WinRT.SourceGenerator\Generator.WinRTAotSourceGenerator\_5e_Randomiser.AppShell.WinRTVtable.g.cs(4,2,4,121): error CS1729: 'WinRTExposedTypeAttribute' does not contain a constructor that takes 3 arguments 1>Done building project "5e Randomiser.csproj" -- FAILED. [/code] Я попытался исправить следующее: [code]dotnet clean dotnet build [/code] [code]dotnet workload install maui-windows [/code] [code]Re-Creating a new project [/code] [code]dotnet restore dotnet build [/code] [code]Installing .NET 9.0 through - [link][1]