I used an ASP.NET Wizard control where I have used several panels in a wizard step. Each panel has a square that is a style display: None. When the user clicks on the "+" button, I toggle the class and change the visibility in the display: block and it works fine. Now I tried to read the values of controls from the panel Controls whose panels are set to appear. But it does not seem to work that it looks correct for all the panels, even if there is a style display in it: any
I tried to do this:
if ((this.Form.FindControl ("ContentPlaceHolder1"). FindControl ("wizard"). FindControl ("panel" + i).) Visible {// where I count current. A constant command like Panel 1, Panel 2, etc. ... executes this code, even if the panel is hidden in the browser)
style display and control visibility are two different t hings. If you set control to visible = 'false' ; The server does not send / control this control at all on the client side. Display Style on the other side: None No; This will not be shown just because of CSS style. then display: none ! = Visible = 'false' . If you need a post code that display is set to none ; You can add hidden field next to your panel ; Set its value with javascript in visible / hidden and then set the value of hidden files to determine visibility on the server side. Please.
No comments:
Post a Comment