I have had a project for a while, that worked fine. I didn't touch it for about a month and I believe in that time the new version (Fall build 1709) of Windows landed. Currently, neither my project, nor the sample project (which I downloaded as a sanity check that there's nothing wrong with my code) for Windows MediaElement work for me. Here is the code being called:
StorageFile file = await openMediaFile.PickSingleFileAsync();
demoMedia.AutoPlay = true;
IRandomAccessStream stream = await file.OpenAsync(FileAccessMode.Read);
demoMedia.SetSource(stream, "");
demoMedia.Play();
The code crashes on demoMedia.SetSource(stream, "");
with an error System.IO.FileNotFoundException: 'The specified module could not be found. (Exception from HRESULT: 0x8007007E)'
. Does anyone know what could be the cause and how to fix it? I tried using demoMedia.SetPlaybackSource(MediaSource.CreateFromStorageFile(file));
(I used setsource before and it worked fine), but that results in: System.TypeLoadException: 'Requested Windows Runtime type 'Windows.Media.Core.MediaSource' is not registered.'
. I assume something broke/ was changed with the update and now the module is either named somehow else, or is missing?
User contributions licensed under CC BY-SA 3.0