本文介绍了LinkBut​​ton的帮助的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好,

我想在数据库中的任何用></term>括起来的术语上创建一个LinkBut​​ton.标签.我的问题是如何在数据库中创建LinkBut​​ton,而不是当前如何使用它.现在,我将匹配的术语存储在占位符中.
谢谢!


foreach(DataRow行)
{

System.Text.RegularExpressions.Regex regex = new System .Text.RegularExpressions.Regex((?? == term))* *(?=</term>)");
System.Text.RegularExpressions.Match match = regex.Match (row ["Definition"].ToString());

LinkBut​​ton lb1;
lb1 = new LinkBut​​ton();
lb1.Text = match.ToString();
PlaceHolder2.Controls.Add(lb1);

lb1.Click + = new EventHandler(lb1_Click);

}

Hello,

I would like to create a LinkButton on any term in the database that is enclosed by <term></term> tags. My problem is how do I create the LinkButton in the database and not how I currently have it working. Right now I am storing the matched term in a placeholder.
Thanks!!


foreach (DataRow row in rows)
{

System.Text.RegularExpressions.Regex regex = new System.Text.RegularExpressions.Regex("(?<=<term>). *(?=</term>)");
System.Text.RegularExpressions.Match match = regex.Match(row["Definition"].ToString());

LinkButton lb1;
lb1 = new LinkButton();
lb1.Text = match.ToString();
PlaceHolder2.Controls.Add(lb1);

lb1.Click += new EventHandler(lb1_Click);

}

推荐答案


这篇关于LinkBut​​ton的帮助的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-23 09:36