0

Is there a solution to cast a winrt StorageFile object to FILE handler (_iobuf). I am trying to use external code with UWP application in which reading file using fopen gives This functionality is not supported in the context of an app container error.

I was looking at this solution: How can I get a Win32 HANDLE for a StorageFile or StorageFolder in UWP? but it is converting StorageFile to ComPtr and running external app with runFullTrust capability is not the best option.

undo994
  • 1
  • 1
  • The link you point is *the* way to do it. ComPtr has nothing to do with external app or funFullTrust capability, it's just the fact you're using COM (which you already do when you use WinRT). But "This functionality is not supported in the context of an app container error" means you can't do this, because in fact of (app container) security. – Simon Mourier Apr 13 '23 at 10:59

0 Answers0