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

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Service | Customer Service, Contact Center, Fie...
Suggested Answer

Prefill Start and End Dates in Booking Recurrence

(2) ShareShare
ReportReport
Posted on by 2,911

When selecting Booking Recurrence related to Agreement Booking Setups we get a dialogue box that opens and by default is populated with todays date as Start Date and End Date is 7 days.

pastedimage1664777117883v1.png

I have prepopulated this by setting the xml in the msdyn_recurrencesettings as below:

daily10/28/202210/27/2023

On this project however we need the users to populate the recurrence pattern although they should not need to change the start and end dates as these are already populated on the Quote Booking setup in the msdyn_timewindowstart and end dates which are date only.

So prefilling the msdyn_recurrencesettings to populate the start and end date isn't acceptable as we can't then easily check if the msdyn_recurrencesettings has been created by the user as it would already exist.

Any ideas on how to populate these two fields without setting the msdyn_recurrencesettings on create.

There is a Microsoft Idea https://experience.dynamics.com/ideas/idea/?ideaid=7581b15b-f85c-e811-bd6d-0003ff68b9c6 for this as well.

  • Suggested answer
    Inogic Profile Picture
    766 on at
    Hi,
     
    The Microsoft Idea is basically acknowledging the same limitation discussed in the forum. Today, Dynamics 365 does not provide any supported way to prepopulate only the Start Date and End Date in the Recurrence dialog from related records (like Quote Booking Setup) unless the system actually creates the msdyn_recurrencesettings record.
    The Recurrence dialog works in a very fixed way:
    • If msdyn_recurrencesettings already exists, it uses that.
    • If it doesn’t exist, it always defaults to today and today + 7 days.
      It does not read values from msdyn_timewindowstart, msdyn_timewindowend, or any other booking setup fields, and there’s no hook (JavaScript, plugin, or parameter) to inject values when the dialog opens.
    Because of that, pre-creating msdyn_recurrencesettings just to populate dates isn’t a good option when you need to know whether the user actually configured recurrence the record would already be there.
    So, the short, honest answer is: this isn’t possible in a supported way right now. The best you can do is let users set the recurrence pattern and then validate or align the dates afterward, or enforce server-side validation. Until Microsoft addresses that Idea, there’s no clean solution that meets the requirement exactly.

    Hope this helps.
     
    Thanks!
    Inogic
  • Suggested answer
    Suriyanarayanan V Profile Picture
    134 on at

    You’ve run into a long‑standing limitation in the Field Service recurrence engine.
    Unfortunately:

    There is no supported way to pre‑populate only the Start Date and End Date in the Booking Recurrence dialog without also creating the full msdyn_recurrencesettings XML.

    And you’re absolutely right — once you create msdyn_recurrencesettings, the system assumes the recurrence pattern already exists, so you lose the ability to detect whether the user actually configured it.

    This is a known product gap, and the Idea you linked is the correct one.

    Why the dialog always defaults to “today → +7 days”

    The Booking Recurrence dialog is not driven by:

    • msdyn_timewindowstart

    • msdyn_timewindowend

    • Agreement Booking Setup dates

    Instead, it uses internal defaults unless a valid msdyn_recurrencesettings XML already exists.

    Microsoft has never exposed a way to override only the date fields.

    Why you cannot set only the dates

    The recurrence dialog expects a fully valid recurrence XML.
    If you populate only the dates:

    • The XML becomes invalid

    • The dialog cannot parse it

    • The system falls back to default values (today → +7 days)

    If you populate the full XML:

    • The dialog loads your values

    • But now you cannot detect whether the user actually configured recurrence

    • And users may not change the pattern because it appears “already set”

    This is exactly the scenario you described.

    Supported / recommended patterns

    ✔️ Option 1 — Let the dialog use defaults (Microsoft‑recommended)

    This is the only fully supported approach today.

    You allow the dialog to open with:

    • Start Date = today

    • End Date = today + 7 days

    Then the user must manually adjust the dates.

    This is not ideal, but it avoids corrupting recurrence settings.

    ✔️ Option 2 — Pre‑populate dates after the user saves the recurrence

    A common workaround:

    1. Let the user open the dialog with default dates

    2. User configures the recurrence pattern

    3. After save, run a plugin/flow to:

      • Read the user’s recurrence XML

      • Replace only the start/end dates with your Quote Booking Setup dates

      • Save the updated XML back

    This preserves:

    • User‑defined pattern

    • Your required dates

    And avoids pre‑creating the XML.

    ✔️ Option 3 — Use a custom UI (PCF) instead of the built‑in dialog

    Some partners build a custom recurrence editor that:

    • Reads the Quote Booking Setup dates

    • Forces the user to choose a pattern

    • Generates valid XML

    • Writes directly to msdyn_recurrencesettings

    This is fully supported because you are not modifying the internal dialog — you are replacing it.

    What is not supported

    • Pre‑populating only Start/End dates without a full recurrence XML

    • Injecting partial XML into msdyn_recurrencesettings

    • Modifying the built‑in dialog behavior

    • Forcing the dialog to read dates from other fields

    These are not supported and will break unpredictably.

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Women in Power Builds Momentum

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders

These are the community rock stars!

Leaderboard > Service | Customer Service, Contact Center, Field Service, Guides

#1
Syed Aqib Raza Profile Picture

Syed Aqib Raza 42

#2
11manish Profile Picture

11manish 31 Super User 2026 Season 2

#3
Travis South Profile Picture

Travis South 25

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans