I have use embedded code to assign the value to label’s text property.But the assign value is not rendering.Here is my code sample,
<%lblProposedYear.Text=”Hello”%>
I can not display the text “hello” at the time of page load.
Please help
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Why are you performing this action in the .aspx part why not do this in the .cs backing file at the OnPageLoad point of the code?
Be aware of when during the page life cycle you perform any action on a control. Once you have looked at this explanation of when things happen you may realize that you are doing something before the viewstate is applied:
http://msdn.microsoft.com/en-us/library/ms178472.aspx
Hope this helps.