将数据库的二进制字节转换成图片
摘要:
首先读取出数据byte[] b = drv["image"] as byte[];用byte数组接收数据实例化BitmapImageBitmapImage newBitmapImage = new BitmapImage();之后判断数据是否为空,并作处理,为空给予一个默认图片if (b == null || b.Length <= 0) { this.headerImg.Source = new BitmapImage(new Uri("../templet/images/defaulthead.jpg", UriKind.... 阅读全文
posted @ 2013-01-30 16:13 源坊 阅读(551) 评论(0) 推荐(0) 编辑