Skip to main content
Nintex Community Menu Bar

How to set the selected date of K2Calendar?

  • September 16, 2005
  • 2 replies
  • 12 views

Forum|alt.badge.img+2
I have two K2Calendars in a web page. When the page first starts, the calendars should show the current date as the selected date.

I tried to set the initial values in the K2 studio Data Fields, to which these calendars link. But the values can only be static, they use, for example Today "9/15/2005", but it won't change to "9/16/2005" tomorrow. How can I set the values to be dynamic so the K2 server will always load the current date from the System Clock?

I also tried to set the selecteddate of the k2calendars in the Page_Load event of the asp.net page. But it doesn't take effect.

2 replies

Forum|alt.badge.img+11
  • Nintex Employee
  • September 19, 2005
Member opened formal support request #3172 for this issue. I will post the resolution when available.

Forum|alt.badge.img+1
  • February 13, 2006
Hey there,

I ran into this same issue. I fixed it by calling setCals() on pageload that set the visible date like such:

public void setCals()
{
calStartDate.VisibleDate = DateTime.Today;
calEndDate.VisibleDate = DateTime.Today;
}

That forces the displayed month to be the current month.