将图像设置为背景 [英] Set Image as Background

查看:175
本文介绍了将图像设置为背景的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述


我必须从Xml文件RichtextBox中读取数据,并在图像下读取图像
TextData但不显示在图像TextData下,如何将图像设置为背景.
请帮助我..

Hi,
I Have to Read Data From Xml File RichtextBox With Image under image read Some
TextData but Doesnot Show Under image TextData ,How to set Image as a Background.
Please help me..

推荐答案

要将图像添加为背景,您可以执行此操作(通过C#):
For add image as Background you can do this (via C#):
ImageBrush img = new ImageBrush();
img.ImageSource = (ImageSource)new ImageSourceConverter().ConvertFromString("Image.jpg");
LayoutRoot.Background = img;



如果您想为RichTextBox设置背景图片,据我所知,您不能在Silverlight =(



If you want to set background image for RichTextBox, as I know you cannot do that in Silverlight =(


这篇关于将图像设置为背景的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆