This is a migrated thread and some comments may be shown as answers.

Today Date Decoration

3 Answers 84 Views
Calendar
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
vijay
Top achievements
Rank 1
vijay asked on 16 Oct 2015, 09:11 AM

Hello,

 I have two condition.

1. I want two decorate today(Current) date apply  some different color or some border.

2. I don't want to highlight today(Current) date.

Please help me out of this.

 

Thanks

Vijay Chhalotre

3 Answers, 1 is accepted

Sort by
0
Todor
Telerik team
answered on 16 Oct 2015, 04:09 PM
Hello Vijay,

Thank you for your question. You can use the adapter's setTodayCellBorderColor method for both scenarios:

1. calendarView.getAdapter().setTodayCellBorderColor(Color.RED);
2. calendarView.getAdapter().setTodayCellBorderColor(Color.TRANSPARENT);


I hope this helps.

Regards,
Todor
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
0
vijay
Top achievements
Rank 1
answered on 17 Oct 2015, 03:40 AM

Hello Todor,

 Thanks for your response.

I want to display today's date same as other dates. Because my requirement is I applied background color for every month, date according to attendance roster. All dates set background properly, but only today date is not set.

please help me out of this.

0
Todor
Telerik team
answered on 21 Oct 2015, 01:24 PM
Hi Vijay,

Since you don't want the today date marked in a special way, you can apply the following customization:

this.calendarView.setCustomizationRule(new Procedure<CalendarCell>() {
    @Override
    public void apply(CalendarCell argument) {
        if (argument.isToday()) {
            argument.setAsToday(false);
        }
    }
});


Regards,
Todor
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Tags
Calendar
Asked by
vijay
Top achievements
Rank 1
Answers by
Todor
Telerik team
vijay
Top achievements
Rank 1
Share this question
or