Forum Discussion
App is not lunching after installing from MSIX package
- Nov 16, 2020
mohamed96ashraf Possibly issue is working directory. The original MSI/EXE based installer creates a shortcut which is interpreted by MSIX to add it to the start menu. When it does this, any setting for the working directory is ignored, and even if it were not set explicitly in the lnk file, the default behavior was to use the folder of the target exe as the working directory of the new process. If you manually launch you'd also get the exe folder to be the working directory. But under MSIX, the working directory is set to the System32 folder.
PsfLauncher may be used to solve this. With PsfLauncher as the target of the shortcut, it doens't care about the working directory and will use a setting in the config.json file to set the working directory of the ultimate target process. PsfTooling may be used when repackaging to add PsfLauncher and solve this.
TIMOTHY_MANGAN The app is working fine if I lunched it from its folder, but it is crashing only if i started it from the start menu. any idea? I already included all .dll files
mohamed96ashraf Possibly issue is working directory. The original MSI/EXE based installer creates a shortcut which is interpreted by MSIX to add it to the start menu. When it does this, any setting for the working directory is ignored, and even if it were not set explicitly in the lnk file, the default behavior was to use the folder of the target exe as the working directory of the new process. If you manually launch you'd also get the exe folder to be the working directory. But under MSIX, the working directory is set to the System32 folder.
PsfLauncher may be used to solve this. With PsfLauncher as the target of the shortcut, it doens't care about the working directory and will use a setting in the config.json file to set the working directory of the ultimate target process. PsfTooling may be used when repackaging to add PsfLauncher and solve this.