Jump to content
Gert Scholten

Windows Extensions SDK in Delphi VCL

Recommended Posts

I'm trying to use Midi in a Delphi VCL Windows Store app. If I copy the exe from the installed Windows Store version to a random location at my harddrive everything works well. But if I start the same exe from the installed location I don't get sound. The app can find the midi device but cannot open it. It seems that the location where the app is located limits the possibilities.

I'm using the Windows Store provisioning and packaging from Delphi. After some searching I've found a possible solution. I need to add a custom extended SDK: Microsoft.Midi.GmDls. It is already in the folder where Delphi finds the Windows SDK, but now... how can I use it?

Is this possible in Delphi? I only see c# examples where you can add extention SDK's to you project.

So summarized:  can I add "Microsoft.Midi.GmDls" as custom SDK to my Delphi VCL Windows Store package? Or is there another way to play midi with an app in the Windows Store?

Edited by Gert Scholten

Share this post


Link to post
Quote

The app can find the midi device but cannot open it

What is the exact error you get?

In your code, did you test every possible error return?

Share this post


Link to post
4 hours ago, FPiette said:

What is the exact error you get?

In your code, did you test every possible error return?

I don't get an error. Just no sound. If I copy the same exe to a different location all works fine. It has something to do with UWP restrictions I think. If the app is installed from the Windows Store, it executes in a different matter then copied to another location.

Share this post


Link to post
5 hours ago, FPiette said:

What is the exact error you get?

In your code, did you test every possible error return?

Ok... I've found the solution. I needed to add the following to the app manifest:

<PackageDependency Name="Microsoft.Midi.GmDls" MinVersion="1.0.0.0" Publisher="CN=Microsoft Corporation, O=Microsoft Corporation, L=Redmond, S=Washington, C=US" />

  • Like 1

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×