cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Regular Visitor

Can't update field with value of calculated text label

I have a fairly simple form that has a field to enter a user's e-mail (which functions for us as a "Property" such as "this hotel@mycompany.com") and from there it populates the label of another datacard  (OSM) with that user's manager's e-mail so it doesn't have to be looked-up or entered manually. The formula to get the managers's e-mail is

Default = Office365Users.Manager(Property_val.Selected.Email).Mail

and it works great. However, I can't get the update to take the value and update the SP list item with

OSM_txt.Text

What am I missing?

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Community Support
Community Support

Hi @TrevorSDG ,

Could you please share a bit more about the "OSM" field in your SP List? Is it a Text type column or a Person type column?

 

1. If the "OSM" field is a Text type column in your SP List:

Please consider set the Update property of the OSM Data card in your Edit form to following formula directly:

Office365Users.Manager(Property_val.Selected.Email).Mail

 

2. If the "OSM" field is a Person type column in your SP List:

Please consider set the Update property of the OSM Data card in your Edit form to following:

{
  Claims: "i:0#.f|membership|" & Lower(Office365Users.Manager(Property_val.Selected.Email).Mail),
  DisplayName: Office365Users.Manager(Property_val.Selected.Email).DisplayName,
  Email: Office365Users.Manager(Property_val.Selected.Email).Mail,
  Department: "",
  JobTitle: "", 
  Picture: ""
}

 

Please consider take a try with above solution, check if the issue is solved.

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
Highlighted
Super User III
Super User III

@TrevorSDG 

A few questions for you good sir!

What data type is the column OSM in SharePoint?

  • This should be a single line text field. 
  • It should not be a People field

What code have you used in the Update property of the Card?

  • I assume you are referencing the blurred out label called OSM_txt
  • Put this code in the Update property of the Card

 

OSM_txt.Text

 

What if your SharePoint field must be a People field?

 

{  
    '@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser",  
    Claims: "i:0#.f|membership|" & Lower(Office365Users.Manager(Property_val.Selected.Email).mail), 
    DisplayName: Office365Users.Manager(Property_val.Selected.Email).displayName,  
    Email: Office365Users.Manager(Property_val.Selected.Email).mail
}

 

Please try these initial suggestions.  If it does not work please take a screenshot with the left panel showing and highlighting the label.  Make sure the Update property is showing in the screenshot.

---
Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a"Thumbs Up."

 

Highlighted
Community Support
Community Support

Hi @TrevorSDG ,

Could you please share a bit more about the "OSM" field in your SP List? Is it a Text type column or a Person type column?

 

1. If the "OSM" field is a Text type column in your SP List:

Please consider set the Update property of the OSM Data card in your Edit form to following formula directly:

Office365Users.Manager(Property_val.Selected.Email).Mail

 

2. If the "OSM" field is a Person type column in your SP List:

Please consider set the Update property of the OSM Data card in your Edit form to following:

{
  Claims: "i:0#.f|membership|" & Lower(Office365Users.Manager(Property_val.Selected.Email).Mail),
  DisplayName: Office365Users.Manager(Property_val.Selected.Email).DisplayName,
  Email: Office365Users.Manager(Property_val.Selected.Email).Mail,
  Department: "",
  JobTitle: "", 
  Picture: ""
}

 

Please consider take a try with above solution, check if the issue is solved.

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Highlighted

Thought I included the sp column types but missed it. Because the requirement was for it to be of type "people", I tried your line of code for updating the  "people" field in and it worked perfectly.

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

News & Announcements

Community Blog

Stay up tp date on the latest blogs and activities in the community News & Announcements.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Community Highlights

Community Highlights

Check out the Power Platform Community Highlights

Top Solution Authors
Top Kudoed Authors
Users online (10,106)