当我点击附加到colorPickerExtender的文本框时,我想增加面板的高度。当我添加我的javascript函数时,该函数不起作用并且不会改变我的面板的大小。
<asp:TextBox ID="tbColorCode" runat="server" CssClass="textBox" MaxLength="7" onfocus="tbColorCode_ClientClicked();" ></asp:TextBox>
<asp:ColorPickerExtender ID="colorPicker" runat="server" TargetControlID="tbColorCode" PopupButtonID="tbColorCode" PopupPosition="BottomLeft" ></asp:ColorPickerExtender>
我的java脚本文件:
function tbColorCode_ClientClicked() {
document.getElementById("pnlcolorChooser").setAttribute("style","Height:250px");
}
我的导入javascript:
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">
<script src="..\Scripts\colorPickerManager.js" type="text/javascript"></script>
我的asp小组:
<asp:Panel ID="pnlcolorChooser" runat="server" CssClass="modalPopup" Width="500">
谢谢