How to show how many other events in month views?

4 posts, 0 answers
  1. 宏吉
    宏吉 avatar
    40 posts
    Member since:
    Mar 2017

    Posted 20 Jul 2017 Link to this post

    I want to change the dots to how many else events in that day ,show like one more event will show +1

    How to do that?

  2. Tyler
    Tyler avatar
    19 posts
    Member since:
    Jul 2017

    Posted 21 Jul 2017 in reply to 宏吉 Link to this post

    You can do this in the dataBound event of the scheduler:

    if(e.sender.view().title == 'Month'){

    where those little '...' bars have the are a span in a div with class .k-more-events. Of course, you would change the text to the number count instead of just a hard coded +1. You will have to adjust font size and size of that bar to fit the text, which you would do in that loop.

    The scheduler has an occurrencesInRange() function to get a list of events within a time range to get the amount of events in a day (I am not 100% sure if it will count the events it truncates in month view, I would think it would... but if it doesn't you will need custom logic to get those).

  3. 宏吉
    宏吉 avatar
    40 posts
    Member since:
    Mar 2017

    Posted 23 Jul 2017 Link to this post

    Yes, that is what I need, but how to know the date in $('.k-more-events>span') 
  4. Ivan Danchev
    Ivan Danchev avatar
    2062 posts

    Posted 24 Jul 2017 Link to this post

    Hello Hung-chi,

    We have a HowTo article showing how the Scheduler's month view can be extended, in order for the number of the hidden events to be displayed. You can find it here.

    Ivan Danchev
    Progress Telerik
    Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Back to Top