First your second question. Do a google search as there are many examples already wrote on how to do what you are asking.
Secondly, unless you are clicking a button or raising some other event on the server, the above code will never work. You have to options:
1: Raise an event on the server when the user moves their mouse over a selected area and hide the panel
2: Use javascript instead.
Javascript is the better option for this as making another round trip to the server seems pointless just to unhide a panel. However, there is a caveat. A .NET control that has its visiblity property set to false is never placed on the page anywhere in code when the page is rendered so, what you would need to do, is something like this:
<div style="visiblity:hidden;">
<asp:panel runat=server id="panel1" visible="true" />
</div>
This will render the panel to the page, just inside a hidden div, so your javascript only needs to set the visibility style of the div to visible.
hth
================================================== =========
Read this if you want to know how to get a correct reply for your question:
http://www.catb.org/~esr/faqs/smart-questions.html
^^Took that from planoie's profile^^
^^Modified text taken from gbianchi profile^^
================================================== =========
Technical Editor for:
Professional Search Engine Optimization with ASP.NET
http://www.wiley.com/WileyCDA/WileyT...470131470.html
================================================== =========
Why can't Programmers, program??
http://www.codinghorror.com/blog/archives/000781.html
================================================== =========