Im playing around with Winui3 for my next app. I created a default project from the Blank app, Packaged (winui3 in desktop)
template in visual studio 2022.
When i run the application inside visual studio with the play button, it works. I want to now generate a stand alone .exe file to run the application. To do this i created a self-contained application through the publish option in visual studio that output the following three files: myapp.pri
, myapp.exe
and myapp.pdb
.
But.. when i double click that published myapp.exe file, nothing happens. Just a spinning icon next to my cursor and nothing. No error.
When i first tried publish, it gave me an error. A google told me to edit the .csproj visual studio file and ammend the runtimeidentifier property and drop off the -10 tags on the end of them, which i did. that fixed the publish errors. Apart from this, i have not done anything.
*target framework is .NET 8.0, windows, target OS version 10.0.19041.0, releae, x64.
What am i missing?
Some tips about publishing a single file:
<PropertyGroup>
<WindowsPackageType>None</WindowsPackageType>
<WindowsAppSDKSelfContained>true</WindowsAppSDKSelfContained>
</PropertyGroup>
obj
folder and the bin
folder before publishing.
I've seen reports mentioning that this works...