用javascript可以实现,我这有代码,可以发给你.

解决方案 »

  1.   

    在textbox旁边放一个dplist或button,点击button生成一个calender,然后选择.
    自己编程吧,这是思路
      

  2.   

    我有现成 的javascript代码。但你给的分太少啦。
      

  3.   

    先定义:
    <asp:Panel ID="panel1" Visible="False" style="FILTER: Alpha(Opacity=80,); LEFT: 0px; POSITION: absolute; TOP: 0px" Runat="server">
    <asp:Calendar id="c1" BorderColor="Black" BorderStyle="Solid" BackColor="White" Font-Size="9pt" Height="250px" Width="330px" ForeColor="Black" Runat="server" Visible="true" Font-Names="Verdana" CellSpacing="1">
    <TodayDayStyle ForeColor="White" BackColor="#999999"></TodayDayStyle>
    <DayStyle BackColor="#CCCCCC"></DayStyle>
    <NextPrevStyle Font-Size="8pt" Font-Bold="True" ForeColor="White"></NextPrevStyle>
    <DayHeaderStyle Font-Size="8pt" Font-Bold="True" Height="8pt" ForeColor="#333333"></DayHeaderStyle>
    <SelectedDayStyle ForeColor="White" BackColor="#333399"></SelectedDayStyle>
    <TitleStyle Font-Size="9pt" Font-Bold="True" Height="12pt" ForeColor="White" BackColor="#333399"></TitleStyle>
    <OtherMonthDayStyle ForeColor="#999999"></OtherMonthDayStyle>
    </asp:Calendar>
    </asp:Panel>
    然后再写后台代码:
    private void i1_Click(object sender, System.Web.UI.ImageClickEventArgs e)
    {
    if((bool)ViewState["t1ort2"] == false)
    {
        ViewState["t1ort2"] = true;
    }
    panel1.Style["LEFT"] = "180 px";
    panel1.Visible = true; } private void i2_Click(object sender, System.Web.UI.ImageClickEventArgs e)
    {
    if((bool)ViewState["t1ort2"] == true)
    {
        ViewState["t1ort2"] = false;
    }
    panel1.Style["LEFT"] = "300 px";
    panel1.Visible = true;
    } private void c1_SelectionChanged(object sender, System.EventArgs e)
    {
    if((bool)ViewState["t1ort2"] == true)
        t1.Text = c1.SelectedDate.ToShortDateString();
    else
                    t2.Text = c1.SelectedDate.ToShortDateString();
    panel1.Visible = false;
    }