[英]Loading Image in Silverlight
我想創建一個WritableBitmap並顯示從流到Image對象的位圖。 如何在Silverlight中做到這一點。 我正在做以下不起作用的事情。
Image img = new Image();
System.IO.Stream stream = File.OpenRead("1.bmp"); //Getting access permission error
WriteableBitmap bmp1 = new WriteableBitmap(100, 100);
bmp1.SetSource(stream);
//do operations with bmp1
img.Source = bmp1;
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.