我可以在LightSwitch屏幕中点击一个字段(超链接)吗? [英] Can I make a field in LightSwitch screen clickable (hyperlink)?

查看:64
本文介绍了我可以在LightSwitch屏幕中点击一个字段(超链接)吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个带有"网站"的数据库。领域。现在它显示为直文。有没有办法让字段显示为超链接,以便用户点击链接并启动网站?

I have a database with a "website" field. Right now it appears as straight text. Is there a way to make the field display as a hyperlink so the user can click on the link and launch the website?

Dave。

推荐答案

Dave,



以下链接可能会为您提供一些指导。



http://dotnettim.wordpress.com/2011/04/14/lightswitch-creating-a-masked-password- textbox-control /

$
本文介绍如何添加屏蔽密码控件。在第二步中,将System.Windows.Controls.PasswordBox类型的自定义控件添加到屏幕上。



在您的情况下,请将其设置为System.Windows.Controls.HyperLinkBut​​ton。



忽略文章中的其余步骤并参考此主题中的数据绑定语法。



http://dotnettim.wordpress.com/2011/04/17/lightswitch-creating-a-masked-password-textbox-part-2/



超链接包含目标名称属性。如果您希望页面在新窗口中打开,则应将此属性设置为字符串值"_blank"。为此,请单击"添加数据项"按钮并添加一个名为prpBlank的新本地字符串属性。



在屏幕的_Activated事件中,添加以下代码:
$


Dave,

The following link might provide you with some guidance.

http://dotnettim.wordpress.com/2011/04/14/lightswitch-creating-a-masked-password-textbox-control/

The article describes how to add a masked password control. In the second step, a custom control of type System.Windows.Controls.PasswordBox is added onto the screen.

In your case, set this to System.Windows.Controls.HyperLinkButton instead.

Ignore the remaining steps in the article and refer to the data binding syntax in this thread.

http://dotnettim.wordpress.com/2011/04/17/lightswitch-creating-a-masked-password-textbox-part-2/

Hyperlinks contain a target name property. If you want the page to open up in a new window, this property should be set to a string value of "_blank". In order to do this, click on the 'Add Data Item' button and add a new local string property called prpBlank.

On the _Activated event of your screen, add the following code:


prpBlank = "_blank"


这篇关于我可以在LightSwitch屏幕中点击一个字段(超链接)吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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