felix
November 13, 2024, 8:33am
1
Hello,
is this also possible in the public forms?
https://community.plumsail.com/t/set-current-user-as-requestor/7371
https://community.plumsail.com/t/populate-created-by-with-current-user/8935
https://community.plumsail.com/t/current-logged-in-user-details/11521
Because there are functions used which with "sp" and I wondered, if these are only usable in SharePoint Forms.
We wanted to retrieve, e.g. user mail or address, which are already available in the entra id or spo-profile of the users.
Thanks for the help,
Felix
Hi @felix ,
It's possible in Public forms with an Account control . Retrieving the email address and name is trivial, while other fields will require a little more tinkering.
Let me know if this helps.
felix
November 18, 2024, 5:48pm
3
Thanks @IliaLazarevskii for the quick reply.
I got mail and displayName to work pretty easily as you mentioned.
Could you give me more hints on how we can access custom attributes from the user profile.
I have already searched the forum and online for this. I couldn't really get it to work in the public forms - https://community.plumsail.com/t/user-profile-custom-properites/8472 .
Which way would you recommend to get to the custom user attributes?
Thanks and all the best,
Felix
Hi @felix ,
Try looking into the properties of fd.account: Form Manager — Plumsail Web Forms Documentation
You can check the list of properties like this:
console.log(Object.keys(fd.account));