Blend 2中的简单超链接 [英] Simple hyperlink in Blend 2
本文介绍了Blend 2中的简单超链接的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有一个我正在编辑的Silverlight视频播放器的XAML文件,我需要在顶部添加文本超链接。是否有一种快速简便的方法来获取一个名为"archive"的文本块。并将其链接到外部现有网页(在新窗口中)?
I've got an XAML file for a Silverlight video player that I'm editing and I need to add a text hyperlink to the top. Is there a quick and easy way to take a text block that's called something like "archive" and link it to an external existing webpage (in a new window)?
推荐答案
你可以创建一个HyperlingButton。
You can create a HyperlingButton.
HyperlinkButton hyp = new HyperlinkButton();
hyp.NavigateUri = new Uri(URL);
hyp.Content = "Some Text for content";
hyp.TargetName = "_blank";
并将控件添加到您的页面。
And add the Control to your Page.
这篇关于Blend 2中的简单超链接的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文