none
Desktop Extension is not working on microsoft store app

    Question

  • Hi,

    I have a Badges Printing project(SelfCheckIn) in which we have used two projects. First one is UWP project and second one is  desktop extension(PrintSilently.exe) for the printing purpose. Now I have two projects and I have create a single package for uploading this two on Microsoft store and following this link for creating the package - https://stefanwick.com/2018/04/06/uwp-with-desktop-extension-part-1/ .

    So I have created a new project(SelfCheckInPackage) inside same solution and referenced the both project and set as entry point to SelfCheckIn. Please see the screenshot on below link-https://social.msdn.microsoft.com/Forums/getfile/1442827.

    Now, When I test my application through the sideloading the package, the all functionality working fine. But the application is not working correctly when I have publish the app for the Microsoft store. PrintSilently.exe is not giving the prints. 

    Can someone please tell me what I have missing?

    Thanks 

    Nikhilesh

    Friday, May 24, 2019 9:41 AM

All replies

  • Hello Nikhilesh,

    Where did you put your extension, in the SelfCheckInPackage? Do you mean your package, uwp project and extension project are in the same solution or in two solutions? Also have you tried to include your exe in your package and set them as content file? How did you call your PrintSilently.exe from your UWP code?

    Best regards,

    Barry


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Monday, May 27, 2019 1:56 AM
    Moderator
  • Hi Barry,

    1) Yes, both project contains in the same solution, And yes I have also calling PrintSilently.exe from my UWP code using below code:

    if (Windows.Foundation.Metadata.ApiInformation.IsApiContractPresent("Windows.ApplicationModel.FullTrustAppContract", 1, 0))
                            {
                                await Windows.ApplicationModel.FullTrustProcessLauncher.LaunchFullTrustProcessForCurrentAppAsync();
                            }

    2) Yes, I also have included the EXE file in a subfolder of the root directory of the package.

    3) I have also put the extension parameter in package.appxmanifest.xml for calling PrintSilently.exe using below code:

    <Extensions>
            <desktop:Extension Category="windows.fullTrustProcess" Executable="win32/PrintSilently.exe" />
          </Extensions>

    After trying all this printing is working through when we sideloading the application, But it's not working at the time of creating a store app. I am not able to find what I have missing.

    Thanks

    Nikhilesh

    • Proposed as answer by room25 Wednesday, May 29, 2019 2:00 PM
    Monday, May 27, 2019 6:14 AM
  • @Nikhilesh,

    The steps looks good. So what about the tutorial 4 which is about upload your package, did you create a appxupload and have you request runFullTrust Approval from store? When you tested with WACK, did you pass this test: https://docs.microsoft.com/en-us/windows/uwp/debug-test-perf/windows-desktop-bridge-app-tests#current-optional-tests 

    I read from Stefan's blog and it seems this test will not block your submission.

    Best regards,

    Barry


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Monday, May 27, 2019 6:28 AM
    Moderator
  • @Nikhilesh,

    By the way, we need to understand more details from your project. Do you have any error info by saying not work? Could you please tried to add logging in your project so that you may be able to understand the exception info from your project?

    Best regards,

    Barry


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Wednesday, May 29, 2019 5:51 AM
    Moderator
  • Hi Barry,

    Its successfully uploaded after checking the code optimization. I had missing this option only.

    Thanks for your valuable reply.

    Cheers

    Nikhilesh


    • Edited by Nikhilesh10 Thursday, May 30, 2019 12:10 PM
    Thursday, May 30, 2019 12:09 PM
  • @Nikhilesh,

    >>Its successfully uploaded after checking the code optimization.

    Hmmm, I'm not so sure of this, do you mean you've got everything worked? You can call your extension exe now?

    Regards,

    Barry


    MSDN Community Support
    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Friday, May 31, 2019 1:33 AM
    Moderator