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

Create CRM Record by using PowerApps APP

 

Hi,

 

I can create CRM record by using PowerApps screen.I fill entity fields from my PowerApps APP but when I clicked button(Save Record to CRM with Flow) if one of entity fields does not contains data,give error and cant save CRM.If all of entity fields arent blank,I can create new CRM record by using APP.How can I add condition to create CRM record even though one of entity fields does not contains data?

 

Is there anyone who can help me about this matter?

 

Thanks a lot

 

3 REPLIES 3
Community Support Team
Community Support Team

Re: Create CRM Record by using PowerApps APP

Hi @Akbulut,

 

Could you please share a screenshot about your app's configuration?

Could you please show more details about the error message?

Do you pass form data from your app to a flow, and then create a record within your Dynamics 365 CRM using flow?

Further, is the field that you mentioned a required (Mandatory) field within your Dynamics 365 entity?

 

If the field that you mentioned is a required (Mandatory) field within your Dynamics 365 entity, you must provided a value for this field within your app. In other words, if you don't provided a value for this required (Mandatory) field, you could not create a record within your D365 entity.

 

As an alternative solution, you could consider take a try to set a default value for this field within the Edit form of your app. If you provide a value for this field, this field would use the value that you provided, if you don't provide a value for this field, this field would use the default value.

 

I have made a test on my side, please take a try with the following workaround:

 

  • Within the Edit form control of your app, unlock the Data card (DataCard1) which contains the field that you mentioned.
  • Set the Update property of the Data card control to following formula:
If(
IsBlank(DataCardValue13.Text),
"Default Value", /* <-- type a default value for this field */
DataCardValue13.Text
)

Note: The DataCardValue13 represents the Text Input control within the Data card.

 

Then if you want to pass this field value from your app to a flow, you could take a try with the following formula:

'YourFlowName'.Run(
...
DataCard1.Update,
...
)

 

Best regards,

Kris

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.
Akbulut
Level: Powered On

Re: Create CRM Record by using PowerApps APP

Hi @v-xida-msft,

 

I shared screenshot APP.

 

When I fill all fields on App, I can create record in dynamics CRM using Flow.(Flow.Run("")).Just one field is mandatory in dynamics crm.(Proje Field).

Other fields are not mandatory in dynamics crm.

For example, When I dont fill Ürün field in App(That field are not mandatory in CRM),It gives error and cant create in CRM.Error like "Flow.Run Error:"Run" ," YenikayıtolusturmaUrun" parameter has invalid value.

 

Best regards,

Akbulut

 

Community Support Team
Community Support Team

Re: Create CRM Record by using PowerApps APP

Hi @Akbulut,

 

I have made a test, and the issue is confirmed on my side.

 

Regardless of the field is required (mandatory) or not, if you don't provided a value for this field when you pass parameters from your app to a flow, the Flow.Run function would always return the following error:

Flow Run Failed. The method Run has an invalid value for parameter "xxxxxx"

 

As an alternative solution,  you could consider take a try to set a default value for this field within the Edit form of your app. If you provide a value for this field, this field would use the value that you provided, if you don't provide a value for this field, this field would use the default value.

 

Please take a try with above solution I provided, then check if the issue is solved.

 

In addition, I think it is not necessary to pass parameters from you app to a flow, and then create record using the flow based on the passed parameters. You could achieve your needs just using PowerApps or Microsoft Flow rather than use them together.

 

Best regards,

Kris

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.

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
Users Online
Currently online: 202 members 5,505 guests
Please welcome our newest community members: