AP.NET misplaced tags can give you big headache

ill formed asp.net tag
I was trying to add a new tab to the existing 2 tabs. I copied some 250 lines of code of the second tab, changed all IDS and ControlIDs for validation etc and finally made the code work. But only to find out that my tab3 would not appear, even though its heading did. I spend some time over this and tried to figure out what I am missing. After all I did not work with ASP.NET TABS before.

Eventually found out that the contents of TAB3 were not showing because they were embedded one level below. I tried to find out what could be the cause but the panel itself seemed fine and were placed adjacent to each other. Then I set out on validating every control inside the TAB, from top to the bottom, starting with panel, tables and gridviews. Found out one anomaly where the code was like this

</tr> </asp:Panel> </table> 

See that </tr> and </table> are interrupted by </panel>. It should have been like this

</tr>  </table> </asp:Panel>

It took me 2 days to find out this was the cause of the problem. Now my TAB3 is working fine and I can work on real code rather than why TAB3 is not working 🙂

Aside | This entry was posted in Tutorials/Tips and tagged , . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s