Click here to Skip to main content
15,881,248 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
How to Pass value of Label (label.text) to the property of a control in ASPX Page (HTML)
I have a some text in Lable i want to pass this text value to a property of a control.
this is also not working:
proberty="<%# Label1.Text %>

Please help me
Posted
Updated 19-Apr-13 21:53pm
v2
Comments
Sandeep Mewara 20-Apr-13 11:24am    
Can you share a little about what exactly are you doing? Further, is label's text static? If so, why not use/assign it directly in page or codebehind when you know the value?
Shagun Bansal 20-Apr-13 11:45am    
Actual i have a value in label u can say some text is contained by a label1 But I want to use that value or text on the html or on aspx page. I can easily acess this on c# code file. Now I have a control on web form and I want to pass its one property equals to that text which is contained by that label. Please help me

 
Share this answer
 
ASP.NET
<asp:label id="lableU" runat="server" text="<%# Label1.Text %>" xmlns:asp="#unknown" />
OR
<asp:label id="lableU" runat="server" text="<%# Label1.Text %>" xmlns:asp="#unknown" />


May This Help You.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900