开发者

C# code for selecting only from todays date from a calendar

开发者 https://www.devze.com 2023-03-13 21:08 出处:网络
Hi iam using a calendar control in my application,i need to select only the date from todays date and future date. am using this calendar control in the content place holder,can any one help me out wi

Hi iam using a calendar control in my application,i need to select only the date from todays date and future date. am using this calendar control in the content place holder,can any one help me out with this problem.

Than开发者_JS百科ks in advance


Try this

protected void Calendar1_DayRender(object sender, DayRenderEventArgs e)
{
    if (e.Day.Date < DateTime.Now.Date)
    {
        e.Day.IsSelectable = false;
    }
}
0

精彩评论

暂无评论...
验证码 换一张
取 消