cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Jimmy1
Level: Powered On

Expense Report Sample - Content Type Error in Approval Flow

Hi Community,

 

I am trying the Expense Report sample app. Thanks to the forum, some known issues mentioned in other posts are resolved. The re-configuration and import are done, and the app seems loaded and functioning except the Approval/Reject step in Flow.

 

In the last step in the Flow where it updates the "Status" value in the SharePoint list, I am running into this "Content Type" message which fails the Flow. It happens to both condition branches. 

 

"message": "The passed-in field \"{ContentType}\" could not be found\r\nclientRequestId:..."

 

Expense Report App.jpg

 

May I have some advice from the community?

Thank you in advance,

Jimmy

 

1 ACCEPTED SOLUTION

Accepted Solutions
Jimmy1
Level: Powered On

Re: Expense Report Sample - Content Type Error in Approval Flow

The instruction page may need to add an additional step for those who are not familiar with the Flow syntax, like myself.

 

Just delete the "{Content Type}" section in both branches will fix this if you are also running into this scenario.

 

Cheers,

Jimmy

View solution in original post

5 REPLIES 5
Dual Super User
Dual Super User

Re: Expense Report Sample - Content Type Error in Approval Flow

Hi @Jimmy1 

 

Can you please share a screenshot of the flow? (The change item status to approved action expanded) there might e some mismatch in the datatype that you are trying to dynamically update with a custom value. 

Highlighted
Jimmy1
Level: Powered On

Re: Expense Report Sample - Content Type Error in Approval Flow

Hi @yashag2255,

Thank you for the reply. I was following this Microsoft Document to setup and import the app: Install and configure the Expense Report sample for canvas apps in PowerApps.

Below is the flow and the only changes I made were to change the SharePoint fields to use my own SharePoint instance and list as highlighted. The rest of the setup of the flow remains as it comes with the package imported. If further details needed, please let me know.

Expense Report App_2.jpg

 

Thank you,

Jimmy

Dual Super User
Dual Super User

Re: Expense Report Sample - Content Type Error in Approval Flow

Hi @Jimmy1 

 

What is the {Content Type} column being used for? I do not see that in the template. Can yu share what is the datatype of this column on sharepoint?

Jimmy1
Level: Powered On

Re: Expense Report Sample - Content Type Error in Approval Flow

Hi @yashag2255,

To my best knowledge, the "content type" is a parameter that checks and updates available fields in the SharePoint list. You will find it in the last step in the Approval Flow template. However, the instruction doesn't mention to change anything in that step, maybe that's why you don't see it mentioned.  

 

Expense Report App_3.jpg

In my test runs, the "Inputs" box seems working because the record details are returned from my SharePoint list. But in the "Outputs" box, it says the "content type" isn't found and the Flow fails.

 

 

Expense Report App_4.jpg

 

The full detail in the Inputs body in my test run:

All the SharePoint columns are returned, but there is an additional section, see the last section with underline, where it returns "{Content Type}" as a field.

 

{
"Title": "Jimmy's test",
  "DateSubmitted": "2019-06-20",
  "StartDate": "2019-06-20",
  "EndDate": "2019-06-21",
  "Cost_x0020_Center": {
    "Value": "XXXXX",
    "@odata.type": "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedReference"
  },
  "Comments": null,
  "Status": {
    "Value": "Approved",
    "@odata.type": "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedReference"
  },
  "ApproverName": {
    "@odata.type": "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser"
  },
  "{ContentType}": {
    "@odata.type": "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedContentType"
  }
}

 

In the Outputs Boday box, apparently, it couldn't recognize this field because the SharePoint list doesn't have it. And this fails the run.

{
"status": 400,
  "message": "The passed-in field \"{ContentType}\" could not be found\r\nclientRequestId:"
}

 

That's how far I can go in troubleshooting this with my limited knowledge with Flow and PowerApps.

Thanks,

Jimmy

Jimmy1
Level: Powered On

Re: Expense Report Sample - Content Type Error in Approval Flow

The instruction page may need to add an additional step for those who are not familiar with the Flow syntax, like myself.

 

Just delete the "{Content Type}" section in both branches will fix this if you are also running into this scenario.

 

Cheers,

Jimmy

View solution in original post

Helpful resources

Announcements
thirdimage

Power Automate Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

fifthimage

Microsoft Learn

Learn how to build the business apps that you need.

Top Kudoed Authors (Last 30 Days)
Users online (5,804)