Is Windows App Runtime backward compatible #3657
-
Hi, I am working on a WinUI3 application for the desktop application in cpp. I am trying to build the application as a single executable(.exe). So I chose framework dependant unpackaged mode. When we chose a framework dependant unpackaged mode of development for WinUI3 we should explicitly install Windows App Runtime in the end user's machine. I installed the latest Windows App Runtime (version 1.3) on my machine and then tried to run an App that is built for Windows App Runtime (version 1.2), but I got this error saying
Does this mean Windows App Runtime is not backward compatible? Or is there any whay to overcome this drawback? Thank you |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
This would require manually using the bootstrapper API. You can't use the auto initialiser (i.e. you can't use the WindowsPackageType set to None) to do this since this always searches for the version of the Windows App SDK it was shipped with.
you can select any version of the Windows App SDK. If you are using a version of the Windows App SDK that the project wasn't built against, you should perform extra checks. Going forward should be safer, but going backwards is dangerous. It means that you have to take care when using functionality that was introduced in newer versions of the Windows App SDK. C++/WinRT will just use the functionality of the version that the headers were generated against. |
Beta Was this translation helpful? Give feedback.
This would require manually using the bootstrapper API. You can't use the auto initialiser (i.e. you can't use the WindowsPackageType set to None) to do this since this always searches for the version of the Windows App SDK it was shipped with.
If you look at the definition for the MddBootstrapInitialize2 function, you should notice that the first parameter is majorMinorVersion. This allows you to manually select the version of the Windows App SDK that you want to load. This means, if you call it like:
you can select any version of the Windows App SDK.
If you are using a version of the Win…