Skip to main content

Notifications

Customer experience | Sales, Customer Insights,...
Suggested answer

Pre-fill Forms from URL

(0) ShareShare
ReportReport
Posted on by 105

Is ist possible to prefill (hidden) fields from the URL of the webpage.

Example: https://mysite.com/events/event-20200512-0900

Can I somehow get that date and time from the URL into my form?

  • Suggested answer
    protc Profile Picture
    protc on at
    RE: Pre-fill Forms from URL

    Hi,

    I think you should be able to use the Power Automate AI builder to achieve this as well,

    docs.microsoft.com/.../

    I have not tested it but sounds doable.

  • cloflyMao Profile Picture
    cloflyMao 25,202 on at
    RE: Pre-fill Forms from URL

    Hi KE Comm,

    You can achieve it by adding custom typescript code to corresponding ts file(eventregistration.component.ts) of event registration page.

    In the ts file, use 

    this.router.url
    function get full URL then extract date and time from it.

    Process to extraction:

    1. Get "event-20200512-0900" with lastIndexOf function.

    2. Use split function to split date and time value to 3 substrings. 20200512 is the second substring, 0900 is the third.

    Finally, return the extracted value to page.

    The whole process would be bit complex, please feel free to ask any question if you had encountered any trouble when adding custom code.

    Regards,

    Clofly

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

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Announcing Forum Attachment Improvements!

We're excited to announce that attachments for replies in forums and improved…

Vahid Ghafarpour – Community Spotlight

We are excited to recognize Vahid Ghafarpour as our February 2025 Community…

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,965 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 230,817 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans