textbox 有获得焦点事件。 在里面写 Calendar控件 的显示
我写了个例子希望能帮你
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.
cs" Inherits="_Default" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "
http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="
http://www.w3.org/1999/xhtml">
<head runat="server">
<title></title>
<script>
function xianshi(){
document.getElementById("cal").style.display='block';
}
</script>
<style>
#cal{ display:none;}
</style>
</head>
<body>
<form id="form1" runat="server">
<div id="after">
</div>
<asp:TextBox ID="id1" runat="server" onfocus="xianshi();" >
</asp:TextBox>
<asp:Calendar ID="cal" runat="server"></asp:Calendar>
</form>
</body>
</html>