SOLVED

Exe registered with sparse MSIX doesn't launch with identity from Explorer

%3CLINGO-SUB%20id%3D%22lingo-sub-3025534%22%20slang%3D%22en-US%22%3EExe%20registered%20with%20sparse%20MSIX%20doesn't%20launch%20with%20identity%20from%20Explorer%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-3025534%22%20slang%3D%22en-US%22%3E%3CP%3EI'm%20trying%20to%20migrate%20a%20plain%20Win32%20program%20to%20use%20some%20WinRT%20APIs%20using%20a%20sparse%20MSIX%20package.%20I've%20got%20everything%20setup%20based%20on%20various%20documentation%20(also%20%22sparse%22!).%20GetCurrentPackageFullName()%20is%20used%20to%20verify%20whether%20it%20does%20have%20identity.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThe%20problem%20is%20it%20doesn't%20work%20when%20I%20launch%20the%20exe%20in%20Explorer.%20However%2C%20if%20I%20use%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fmsixhero.net%2F%22%20target%3D%22_self%22%20rel%3D%22nofollow%20noopener%20noreferrer%22%3EMSIX%20Hero%3C%2FA%3E%26nbsp%3B(an%20open%20source%20MSIX%20management%20tool)%20to%20start%20the%20process%2C%20it%20does%20launch%20with%20identity.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI%20would%20assume%20if%20the%20identity%20in%20the%20manifest%20file%20didn't%20match%20the%20identity%20in%20the%20AppxManifest%20file%2C%20it%20wouldn't%20work%20at%20all.%20So%20I%20believe%20I%20have%20it%20setup%20correctly.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EIs%20there%20something%20additional%20that%20is%20required%20to%20get%20an%20exe%20to%20launch%20with%20identity%20when%20opened%20like%20any%20other%20exe%3F%20And%2C%20why%20does%20it%20work%20with%20MSIX%20Hero%3F%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E
New Contributor

I'm trying to migrate a plain Win32 program to use some WinRT APIs using a sparse MSIX package. I've got everything setup based on various documentation (also "sparse"!). GetCurrentPackageFullName() is used to verify whether it does have identity.

 

The problem is it doesn't work when I launch the exe in Explorer. However, if I use MSIX Hero (an open source MSIX management tool) to start the process, it does launch with identity.

 

I would assume if the identity in the manifest file didn't match the identity in the AppxManifest file, it wouldn't work at all. So I believe I have it setup correctly.

 

Is there something additional that is required to get an exe to launch with identity when opened like any other exe? And, why does it work with MSIX Hero? 

1 Reply
best response confirmed by KevinS12345 (New Contributor)
Solution
Solved! I was able to get the sample project at https://github.com/microsoft/AppModelSamples/tree/master/Samples/SparsePackages working and that helped narrow it down. Turns out the Assets folder and files must exist relative to the external location. In my test I did not have these setup originally.