Asked by:
MediaEncodingProfile.createFromFileAsync would freeze the app

Question
-
Hi,
I want to trim the video, but keep its original format.
The API MediaEncodingProfile.createFromFileAsync(storageFile) can do that.
But it would have no respond occasionally. Just app hang, and need to stop it manually.
Is anything that I miss, or how to avoid this issue?
OS: Windows 8 Consumer Preview b8250
Best Regards.
R.C.Y
- Edited by R.C.Y Thursday, March 22, 2012 6:21 AM
Thursday, March 22, 2012 6:18 AM
All replies
-
Hi R.C.Y,
What is your code actually, how do you call this method? Could you please try to provide some code that we can reproduce it in our side.
Sincerely,
Bob Bao [MSFT]
MSDN Community Support | Feedback to us
Thursday, March 22, 2012 9:02 AM -
Windows Metro app with Javascript + HTML + CSS.
And partial code is below:
var picker = new Windows.Storage.Pickers.FileOpenPicker(); picker.suggestedStartLocation = Windows.Storage.Pickers.PickerLocationId.videosLibrary; picker.fileTypeFilter.replaceAll([".mp4", ".wmv", ".mpg"]); picker.pickSingleFileAsync().then(function (videoItem) { if (videoItem) { Windows.Media.MediaProperties.MediaEncodingProfile.createFromFileAsync(videoItem).done(function (profile) { console.log("got video profile"); // Cannot reach here occasionally. }); }
});
Best Regards.
R.C.Y
- Edited by R.C.Y Friday, March 23, 2012 1:14 AM
Thursday, March 22, 2012 10:45 AM -
When it happen, ALT+F4 cannot exit the app. And the app will close automatically in seconds after pressing Win key back to desktop.Friday, March 23, 2012 2:50 AM
-
The complete project code is on dropbox
All I did was simple:
1. Choose file
2. MediaEncodingProfile.createFromFileAsync
BR.
----
R.C.YMonday, March 26, 2012 7:48 AM