web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Customize Calendar Con...
Power Apps
Answered

Customize Calendar Control

(0) ShareShare
ReportReport
Posted on by 473

I would like to seek help to implement the customizations to MSCRM calendar control.

I appreciate any help or guidance on the following requests.

Thank you.

1. Default to 'Month' onLoad
I'm aware that the default-to-month has deprecated in the latest calendar control version, and this settings is now configurable via Personal Settings. However, I am required to default to Month on pageLoad for all users by using Javascript, etc.

gymcode_4-1716864113017.png

2. Display Full Calendar Control on Page without Scrollbar
Regardless of screen resolution, I want to have a 'fit-to-screen' control that displays all days in the view without the scrollbar.

gymcode_5-1716864165860.png


3. Different Color Code Based on Condition
I want to display a different color code for different event types, and this condition can be via an optionset value in the entity, etc.

gymcode_6-1716864223361.png

I have the same question (0)
  • Shashank Bhide Profile Picture
    946 Moderator on at

    curious how did you add this control? is it from field service?

  • Verified answer
    MichaelFP Profile Picture
    1,943 Moderator on at

    I would recommend to use a PFC component that do this job here is one that you can do all this stuff that you need.
    Calendar Control | PCF Gallery

    Please mark as solution with you liked my answer.


  • ruihaolrh Profile Picture
    473 on at

    It is a calendar control from the entity level.

    gymcode_0-1717033742781.png

     

  • ruihaolrh Profile Picture
    473 on at

    Thank you, I will give it a try.

  • ruihaolrh Profile Picture
    473 on at

    Hi @Michaelfp , thank you for the suggested PCF control.
    It indeed fulfil many of my requirements.

    gymcode_1-1717492597874.png


    As there is no guide on configuring different colour for each event type (e.g. holidays, work events, personal events), may I know if you have an idea on how the different colour codes can be configured for different event types in Model-Driven App?
    gymcode_0-1717492279207.png

    Based on the notes in Calendar Control PCF Github, it states that 

    • Event Color Field This will change the color of the event. You can use a color field on the event or you can utilize a color field from the resources. Enter the logical name of the attribute. Ex. on Event raw_color, Ex. on Resource raw_resource.raw_color.

    However, I have no clue on this configuration.

    Any help would be greatly appreciated.

    Thank you.

  • MichaelFP Profile Picture
    1,943 Moderator on at

    @gymcode good to know that helped you!

    For the colors, I would recommend you create a collection and include a new Color in Hex value. I don't know your table structure, but here when I implemented, I have table which has the types of the events on Dataverse and handle the color from that table. In the appointment (that was my case), i have the relationship with my custom table to be able to use on the canvas apps.

    ClearCollection(MyEvent,AddColumns(Appointments,"Colors",Lookup(MyCustomTable, EventType = ThisRecord.EventType).Color);


    and i map into the PCF.

     

    Kind Regards.
    Please if my answer help please give me a kudo, if solve you question mark as solution.

  • ruihaolrh Profile Picture
    473 on at

    Hi @Michaelfp ,

    Thank you for your example. May I know if you can guide me on the values of color for each EventType?

    Do you store the color codes, e.g. #ff0000?

    I applied the field mapping of "Event Color Field" to a text field containing the HEX color code, but it doesn't seem to take effect.

    gymcode_0-1717554939212.png

    I also tried mapping 2 field types, OptionSet, and a text field containing the HEX color code.

    gymcode_0-1717561197979.png

    gymcode_1-1717561210298.png

     



  • MichaelFP Profile Picture
    1,943 Moderator on at

    @gymcode did you included in your view theses fields used to map?

  • ruihaolrh Profile Picture
    473 on at

    Hi @Michaelfp , thank you. This was the issue! 

  • ruihaolrh Profile Picture
    473 on at

    @Michaelfp by any chance you see the possibility of the PCF calendar control to display records from multiple entities?

    If it is not possible, what I can think of is to display both views in a dashboard, but it looks a little bad on UX point of view.

    1. User's Leave Entity

    gymcode_0-1718102945162.png


    2. Public Holidays, etc, entity

    gymcode_1-1718102954363.png

     

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 530

#2
WarrenBelz Profile Picture

WarrenBelz 459 Most Valuable Professional

#3
Haque Profile Picture

Haque 314

Last 30 days Overall leaderboard