As you know using PowerApps, we can create or Update the records in the Dynamics 365 CE. Here, in Dynamics 365 CE we have various types of fields in an Entity. So, while working with Lookup type field, we faced an issue where we were unable to create/update the record.
But issue occurred only for Lookup field which was a type of Multi Entity lookup field. We know there are fields with Multi Entity like Customers and Regarding fields.
In this blog, we are going to explain the scenario where we were trying to create “Task” record against a specific Account record. As you know, in the Task entity, there is a Regarding field (multi lookup type) where we can set the specific account.
For this, we used PATCH function to create/update the record where we were setting the value of the Regarding field, but it was unable to set the entity type of the lookup field and showed an error “The type of this argument ‘_reagrdingobjectidid_type’ does not match the Expected type ‘Guid’.Found type ‘Text’.”
You can see error in the below screenshot of the PATCH function which is written on the click of the button to submit the data.
So, we checked why it was unable to set the name of the entity in String format but could not find much on the topic. However, after digging deep in PowerApps, we found that there was a setting in the that allows GUID types data in String format.
To fix this issue, we modified settings of the PowerApps as shown below and were able to set the entity name in the ‘_reagrdingobjectidid_type’ field.
You can see below steps to modify the App settings:
1. Select the App in PowerApps in which you are working and select Edit
2. Once you enter the App, you can see File option at the top and click on it.
3. After clicking you will see the “App Settings,” click on it and select the Advanced settings:
4. After selecting the “Advanced settings,” you will see an option “Use GUID data types instead of strings.” Toggle to Turn Off as shown below:
5. Now SAVE the App and restart. You are all set to start Editing App and will be able to set the Regarding field without any errors.
Hope this helps!
To help evaluate your business needs and design a custom app for your specific requests reach out to us at crm@inogic.com | Read our blog series on Microsoft PowerApps