MultiView for year: month header

2 posts, 0 answers
  1. Daniel
    Daniel avatar
    8 posts
    Member since:
    Sep 2016

    Posted 22 Aug Link to this post

    Hi, 

    I have two question about RadCalendar multi-view mode, annual visualization.

    What I try to do di edit each month name, on header, putting in it the counter of SpecialDays for each month. It's a company holiday calendar, so I need to show, for every month, the total working days (365 - SpcialDays.where(Date.Month == currentMonth, just for example). How I can achieve this behavior?

     

    Second. Seems to be a problem with the control, in full year view. What happen is that if I set MinDateRange/MaxDateRange of the multi-view on values 01/01/2018-31/12/2018, and I set FocusedDate and SelectedDate on first date on interval (1/1/2018), with a layout of 2 rows and 6 columns, setting by code currentViewRow and currentViewColumn to 0/0, what I get as result is the print-screen attached. This will not happen in any other year (before 2017 and after 2018). I think the problem is due to that 22 august 2017 in today date and august month was badly placed as column/row 0-0 by the control himself.

     

    This piece of code is what I use to set the control layout:

     

    <code>

        if (today.Year == year)

                {
                    colForCurrentDate = today.Month <= 6 ? today.Month - 1 : today.Month - 7;
                    rowForCurrentDate = today.Month <= 6 ? 0 : 1;
                    calendar.FocusedDate = DateTime.Now.Date;
                }
                else
                {                
                    calendar.FocusedDate = calendar.RangeMinDate;
                    colForCurrentDate = 0;
                    rowForCurrentDate = 0;                               
                }
                
                calendar.CurrentViewColumn = colForCurrentDate;
                calendar.CurrentViewRow = rowForCurrentDate;

     

    </code>

     

    Is this a bug of the RadCalendar? What I can do in order to resolve this?

     

    Thanks in advance!

  2. Daniel
    Daniel avatar
    8 posts
    Member since:
    Sep 2016

    Posted 31 Aug Link to this post

    Hey guys!

    No way for an answer to these questions?

     

    Thanks in advance.

Back to Top