Get stream of local image. Windows phone 8

烂漫一生 提交于 2020-01-05 07:34:10

问题


I have image ( /Assets/Cat.png ). I need to get stream of this image. I have tried some ways, but all of them were unsuccessfully. What should i do?


回答1:


In order to get the stream of the image use this

Stream myStream = App.GetResourceStream(new Uri("Assets/Cat.png", UrKind.RelativeOrAbsolute)).Stream;


来源:https://stackoverflow.com/questions/18310286/get-stream-of-local-image-windows-phone-8

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!