Problem Setting SelectedDates collection

3 posts, 0 answers
  1. Kerry
    Kerry avatar
    61 posts
    Member since:
    Nov 2008

    Posted 15 Feb 2012 Link to this post


    I'm using a RadCalendar within my WinForms application, I'm having an issue setting the SelectedDates collections programmatically. The code below works only if I uncomment the statement dtDate = new DateTime(dtDate.Year, dtDate.Month, dtDate.Day);   It sets the dates and highlights them correctly when I have multiple dates. If I do not create an instance of a DateTime object as you see below the calendar seems to only accept the first date in my dataset.  This is odd since the DateTime.TryParse statement returns a valid datetime into dtDate variable and I feel its unnecessary to have to set it again.  Using VS2008 Framework 3.5 build 2011.3.11.1116.

    DateTime dtDate;
    foreach (DataRow rw in oDS.Tables[0].Rows)
            DateTime.TryParse(rw["eDate"].ToString(), out dtDate);
           //dtDate = new DateTime(dtDate.Year, dtDate.Month, dtDate.Day);

    Thanks Kerry
  2. Boryana
    Boryana avatar
    330 posts

    Posted 20 Feb 2012 Link to this post

    Hello Kerry,

    Your question has already been answered in the other forum thread you have opened. Please see our answer there. 

    You are not able to see your first forum thread, because it has been transferred to our support ticketing system and therefore is no longer public. This step is needed since we have asked you for a sample project that reproduces the issue.

    We kindly ask you to use just one support channel to contact us. Posting the same questions several times slows down our response time. Please note that threads are handled according to license and time of posting, so if it is an urgent problem, we suggest you use a support ticket, which would be handled before a forum thread.

    Thank you for your understanding and cooperation.

    the Telerik team
    Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
  3. Kerry
    Kerry avatar
    61 posts
    Member since:
    Nov 2008

    Posted 20 Feb 2012 Link to this post

    Sorry not sure how this happened, I only posted it once but I received an error and had to refresh the page and it must have posted the msg again.

Back to Top