I have a Panel control which contains too many child controls. As default it is hidden (display = none) and by click a button it is shown (display = block) in the required Height and Width (NewHeight and NewWidth properties).
I tried to override the origin Width and Height properties, and then the Panel will be AS DEFAULT shown (not hidden). why?
Bader
Member
10 Points
83 Posts
Remove default Properties
Aug 06, 2012 01:01 PM|LINK
Split off from http://forums.asp.net/t/1420431.aspx/1?Remove+default+Properties
Hi,
I have the same problem.
Lets talk abot the Height and Width properties...
I have a Panel control which contains too many child controls. As default it is hidden (display = none) and by click a button it is shown (display = block) in the required Height and Width (NewHeight and NewWidth properties).
I tried to override the origin Width and Height properties, and then the Panel will be AS DEFAULT shown (not hidden). why?
Can you please help me solve this issue?
Regards,
Bader
jkirkerx
Contributor
3750 Points
873 Posts
Re: Remove default Properties
Aug 09, 2012 05:33 AM|LINK
You have to remove the style if you did it server side, and then add it back. if you want to grow the panel, set the style to min-height
.style.add("min-height", "500px")if you set the panel to .visible = true, and then use javascript or Jquery to show or hide the panel, it will corrrupt the postback
so you set the panel to see below in markup or code behind