cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
santpaiva
Helper I
Helper I

Fill form with user name

Hi, I have a form on my App where one of the fields to be filled out is the name of the person who filled it out. Currently the user needs to search for his own name in the DataCardValue to complete the registration. However, I would like to have this DataCardValue filled in automatically and that it was not possible to change it. I tried to use the "User (). FullName" function for this but it is not working. 

Can anybody help me?

1 ACCEPTED SOLUTION

Accepted Solutions

@santpaiva 

 

To configure this, you can set the Default property of the datacard to below expression:

{
'@odata.type':"#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser",
Claims:"i:0#.f|membership|" & User().Email, Department:"", DisplayName:User().FullName, Email:User().Email, JobTitle:"", Picture:""
}

 

Hope this Helps!

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

View solution in original post

4 REPLIES 4
Drrickryp
Super User
Super User

Hi @santpaiva 

Did  you put the User().FullName as the Default property of the control in the card?  If you don't want the user to change it, make the display mode of the card containing the control Disabled.

eka24
Super User
Super User

If you used the User().FullName and it did not work, then what was the result, did you get an error or Blank DataCradValue? if you have those spaces or had "" around it the refer to the formula stated by @Drrickryp 

Also are all your users having user account or you are just using a login where some of the users dont have account?

------------

If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

@santpaiva 

 

To configure this, you can set the Default property of the datacard to below expression:

{
'@odata.type':"#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser",
Claims:"i:0#.f|membership|" & User().Email, Department:"", DisplayName:User().FullName, Email:User().Email, JobTitle:"", Picture:""
}

 

Hope this Helps!

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

Thank you, it's helped me too.

Helpful resources

Announcements
Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Community Call Conversations

Introducing the Community Calls Conversations

A great place where you can stay up to date with community calls and interact with the speakers.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (6,129)