Click here to Skip to main content
15,891,951 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
i am try to set the value dynamically but getting error

XML
<td>
                    <asp:Label ID="Label1" runat="server" Text= '<%# Response.Write('Generate ' + Session["mType"] + ' Template' %>' Font-Bold="true" />
                </td>
Posted
Comments
Dinesh.V.Kumar 13-Feb-14 9:24am    
You can do this from the code page..
label1.Text = Session["mType"];

Regards

1 solution

Why don't you use code behind for this?
C#
Label1.Text = "Generate " + Session["mType"].ToString() + " Template";
Anyway try like this & customize it
ASP.NET
<asp:label id="Label1" runat="server" text="<%= Session[" mtype="].ToString() %>" font-bold="true" xmlns:asp="#unknown" />

And use String.Format or Stringbuilder for string concatenations
 
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