web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Validation error on su...
Power Apps
Unanswered

Validation error on submit/create form in power apps

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

Hello,

I am creating Power Apps from that user can fill the record and record should get saved in dynamics 365.

 

Problem: Whenever i submit the form i get a error stating "Field is Required" or "An entry is required or has an invalid value" and form gets reloaded, whereas i have filled data in all the fields.

 

Screenshots:

Error 1: date is addedError 1: date is addedError 2: after submit form . Form get loaded and shows error.Error 2: after submit form . Form get loaded and shows error.

 

Categories:
  • Tom_Slosse Profile Picture
    1,430 on at

    Hey @VaishaliVyas

     

     

    Why do you need to fill in the time twice?

    I guess it conflicts with eachother, I would try and remove the textboxes for Hours and Minutes.

    As you can fill in the time already in the dates.

     

    Hope this helps

    Kind regards

     

     

    Tom

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hey @Tom_Slosse

     

    I Tried that. But It's not working.

     

  • Tom_Slosse Profile Picture
    1,430 on at

    Hey @VaishaliVyas

     

     

    Does your field in Dynamics accept time?

    Also how do you save all your data back to Dynamics 365?

    So how does the code under the submit button looks like

     

    Kind regards

     

    Tom

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi @Tom_Slosse

     

    In CRM

    Screenshot_5.png

     

    and on submit . code: SubmitForm(EditForm1)

  • Tom_Slosse Profile Picture
    1,430 on at

    Hey @VaishaliVyas

     

     

    Well looks like CRM isnt the problem.

    I guess it is the submit that doenst do the job.

    I would suggest that you take a copy of your current app and try the following on the submit button:

     

    Patch(<datasource>,Defaults(<datasource>), {Title="", <Field>: <NameOfYourControl>.<TypeOfField>,..})

    So in your case it could be something like this:

    Patch(<datasource>,Defaults(<datasource>), {Title="", StartDate: StartDate.SelectedDate, EndDate: EndDate.SelectedDate, Hours: HoursTextbox.Text, Minutes: MinutesTextbox.Text})

     

    Hope this helps

    Kind regards

     

     

    Tom

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    hi @Tom_Slosse

     

    I am trying that but its giving me error.

    Screenshot_2.png

     

    This is my form in power apps:

    where Project, Project Task , Billing code are lookup fields , Start and End Date are Date and Time field, Hours and Minutes are Number filed,where Project, Project Task , Billing code are lookup fields , Start and End Date are Date and Time field, Hours and Minutes are Number filed,comments is text fieldcomments is text field

     

    I have noticed one thing when i open an previosuly created record from Browse screen and edit that record then i can see that changes in my CRM system. But when i try to create a new record it gives me error.

     

     

  • Tom_Slosse Profile Picture
    1,430 on at

    Hey @VaishaliVyas

     

     

    Now you get an error because Hours and Minutes are number fields.

    Are they number fields in Dynamics?

    Otherwise I suggest you change them to text fields

     

    Kind regards

     

     

    Tom

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    hey @Tom_Slosse

     

    Hours and Minutes are Whole number in CRM. Now i was trying to submit form it shows some fields are ewquired.(Project case, Billing Type, Status) fileds are required. values of this fields are automatically created in crm after user save the form.

     

  • Tom_Slosse Profile Picture
    1,430 on at

    Hey @VaishaliVyas

     

     

    I'm not an Dynamics expert so sorry on my behalf but could you try and save everything without any required fields.

    If that works then we are sure the form really submits to Dynamics.

     

    Kind regards

     

     

    Tom

  • vaishali_37 Profile Picture
    84 on at

    Hey @Tom_Slosse

     

    How do i convert Text Field to Number . In  My case Data Type of hours and minutes is number. when i write them inside patch function is gives me error beacuse of that.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 402 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 328

#3
WarrenBelz Profile Picture

WarrenBelz 296 Most Valuable Professional

Last 30 days Overall leaderboard