asp.net object.Attributes.add()方法 [英] asp.net object.Attributes.add() Method
问题描述
例如:
1.
for example:
1.
linkBtnName.Attributes.Add("onmouseover","document.getElementById(''someId'').src=''asdf.gif''");
2.
2.
e.Row.Attributes.Add("OnDblClick", "__doPostBack(''GridView1'',''Select$" + e.Row.RowIndex + "'')");
这是一个js表达式,但是我很困惑!因此,我想对此进行介绍.看到上面有2个Select $,我不知道它在哪里.因为我从未见过像这样使用的人,所以也没有关于它的介绍.请提供有关此主题的信息.
___________________________________________________________________
我的意思是我不知道如何使用对象的attributes.add()方法.
例如:button.attributes.add()
textbox.attributes.add()
It''s a js expression,but I am so puzzled! So I want a introduction about this. See the 2 up there is a Select$, I don''t know where its come. Because I never see one to use like that and I don''t have an introduction about it. Please give information about this topic.
___________________________________________________________________
I mean I don''t know how to use object''s attributes.add() method.
for example:button.attributes.add()
textbox.attributes.add()
推荐答案
"+ e.Row.RowIndex +"''));
" + e.Row.RowIndex + "'')");
这是一个js表达式,但是我很困惑!因此,我想对此进行介绍.看到2上有一个Select
It''s a js expression,but I am so puzzled! So I want a introduction about this. See the 2 up there is a Select
,我不知道它在哪里.因为我从未见过像这样使用的人,所以也没有关于它的介绍.请提供有关此主题的信息.
___________________________________________________________________
我的意思是我不知道如何使用对象的attributes.add()方法.
例如:button.attributes.add()
textbox.attributes.add()
, I don''t know where its come. Because I never see one to use like that and I don''t have an introduction about it. Please give information about this topic.
___________________________________________________________________
I mean I don''t know how to use object''s attributes.add() method.
for example:button.attributes.add()
textbox.attributes.add()
天使,
服务器控件(如Button和label)具有属性(属性),如runat,id,名称,样式.
例如:< asp:label id ="lbltest" runat ="server" style ="display:block" text ="Test" xmlns:asp =#unknown">
这里,id,runat,style和Text是属性,这意味着可以在设计时或运行时设置控件的属性.
希望对您有帮助.
问候,
Jitendra Zaa
Hi Angel,
Server controls like Button and label have properties (attributes) like runat, id, name, style.
Ex : <asp:label id="lbltest" runat="server" style="display:block" text="Test" xmlns:asp="#unknown">
here, id, runat, style and Text are the attribute, which means that attributes of the controls can be set at design time or runtime.
I hope this would help you.
Regards,
Jitendra Zaa
这篇关于asp.net object.Attributes.add()方法的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!