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 :
Customer experience | Sales, Customer Insights,...
Suggested Answer

Need help with the below form

(0) ShareShare
ReportReport
Posted on by 200

Need the below details to be prepopulated with logged in user details. Any solutions or ideas please?

event-populate-requirement.png

Thanks

I have the same question (0)
  • Fariha Asmat Profile Picture
    216 on at

    Hi Swathi,

    You can run a workflow on the load of form, which will populate these fields with logged in user name and email id.

  • cloflyMao Profile Picture
    25,210 on at

    Hi Swathi,

    You could build an entity list, set contact as its source entity,

    and Enable Entity Permissions to make sure that only logged user could retrieve his/her own data via the Odata Feed link.

    3568.JPG

    0207.JPG

    Then request the endpoint on Event registration page with code below and populate the form from retrieved result:

      var req = new XMLHttpRequest();
      req.open("GET", Url + "/_odata/openContacts", true);
      req.setRequestHeader("Accept", "application/json");
      req.setRequestHeader("Content-Type", "application/json; charset=utf-8");
      req.setRequestHeader("Prefer", "odata.include-annotations=\"*\"");
      req.onreadystatechange = function() {
        if (this.readyState === 4) {
          req.onreadystatechange = null;
       if (this.status === 200) {
          var results = JSON.parse(this.response);
              for (var i = 0; i < results.value.length; i++) {
                    var firstname = results.value[i]["fullname"].split(" ")[0];
                    var lastname = results.value[i]["fullname"].split(" ")[1];
                    var email = results.value[i]["emailaddress1"];
                  }
         } else {
                   console.log(this.statusText);
            }
          }
        };
      req.send();

    Regards,

    Clofly

  • Suggested answer
    ShravanSuri Profile Picture
    1,255 on at

    Hey Swathi,

    Currently, customization using code is the only way to pre-fill this form, as Clofly points out below. Have you tried the steps she mentioned - do they work for you?

    Thanks

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 Stars!

Congratulations to our 2025 Community Spotlights

Thanks to all of our 2025 Community Spotlight stars!

Leaderboard > Customer experience | Sales, Customer Insights, CRM

#1
ManoVerse Profile Picture

ManoVerse 131 Super User 2026 Season 1

#2
Jimmy Passeti Profile Picture

Jimmy Passeti 46 Most Valuable Professional

#3
NeerajPawar Profile Picture

NeerajPawar 41

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans