I am trying to dynamically hide a Div within a FormView control. The problem though is that the code behind can't "see" it and so far I haven't found a way to get around it. When the Div isn't nested, then it's no problem. Unfortunately I can't avoid nesting it.
I've run into similar issues with other controls, but have been able to get to the control by way of FormView.FindControl and CType-ing it to the control type. However, for the Div, I can't seem to find anything that CType accepts. Other semi-related solutions suggested HTMLGenericControl, but that didn't work. In fact one of the other solutions suggested to the poster to use something else for his issue than HTMLGenericControl because he could never get it to work either. (That solution was to something that doesn't apply here btw).
Any ideas? If there is another way to dynamically hide the Div, that would be good too. The code behind will know "when", I just need to be able to tell the page!