I am trying to access a asp:panel in an external script to make it not visible,but it does not seem to be working. When the Script is in the .aspx file it works fine though.Any suggestions?
In the .aspx file
<script src="App_Themes/custom.js"></script>
<asp:Button ID="descriptionButton" Text="Description" runat="server" OnClientClick="descButton(); return false;" />
<asp:Panel ID="desciptionPanel" runat="server">
///random stuff
<asp:panel>
in the custom.js file
function descButton() {
var desc = document.getElementById('<%=desciptionPanel.ClientID%>');
desc.style.visibility = "visible";
desc.style.height = "800px";
}
Thanks in advance
Aucun commentaire:
Enregistrer un commentaire