Publish a MAUI app for the Microsoft Store returns a ProcessorArchitecture error

70 Views Asked by At

I'm trying to publish my .NET 8 MAUI application to the Windows Store after removing the dependency with a library (I can tackle the problem later).

The problem I face now is this error:

Packaged .NET applications with an app host exe cannot be ProcessorArchitecture neutral. Please specify a RuntimeIdentifier or a Platform other than AnyCPU.

I read a few posts:

So, I opened the Configuration Manager and added a new configuration like that

enter image description here

and I tried to recreate the package but with the same error. Then, I read I have to add in the project file this line

<RuntimeIdentifiers>win-x86;win-x64;win-arm64</RuntimeIdentifiers>

and this is not working; it generates a lot more errors.

The application settings looks like that

enter image description here

How can I fix this issue?

0

There are 0 best solutions below