i want to get ‘display’ css value of a server side div!
the code below does not work :
if (div.Style["display"] == "none")
{
div.Style.Add("display", "table-row");
}
how can i get that value in c#?
thanks in advance
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.
You can’t do what you are trying to do on the server side. The Style property only works with the inline styling. Consider client side JavaScript.
<div id="div" runat="server" style="display: none;">Foo</div>