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 / Form Validation with c...
Power Apps
Unanswered

Form Validation with custom card not working

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

@LukeW-MSFT

 

This is driving me nuts. Can anyone please advise me on what the issue is here and how to overcome it? 

 

  • Created an app from a Sharepoint custom list
  • Deleted the default label then pasted an existing label into the data card to keep styling consistent
  • Deleted the text input box and pasted in a dropdown menu to keep styling consistent
    • Dropdown Items property set to:
    • [" ", "Completed", "Completed w/ Comments", "Exceptions Taken"]
  • Set the data card Required property to true

If I leave the dropdown value set to "  ", then SubmitForm(), no Error Message appears and the form is successfully submitted. Text boxes within the form error-out correctly (see below), it just seems to be the dropdown. 

2018-06-15_7-28-18.png

 

I cannot for the life of me figure out why. 

Categories:
I have the same question (0)
  • v-xida-msft Profile Picture
    Microsoft Employee on at

    Hi @ericonline,

     

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

     

    I have made a test on my side and don't have the issue that you mentioned. If I leave the Drop down (new pasted one) control empty, when I submit the form, the error message shows up as below:6.JPG

     

     

    On your side, please check if the Update property of the DataCard control associated with the Drop down control (new pasted one) is set to following formula:

    Dropdown1.Selected.Value

    Note: The Dropdown1 represents the new pasted Drop down control on your side.

    7.JPG

     

    In addition, please also check if the Error Message Label is existed within the DataCard control (Associated with the Drop down control):8.JPG

    If the Error Message Label is not existed within the DataCard control, please add a Label control within the DataCard and set the Text property of this Label control to following formula:

    Parent.Error

     

    Best regards,

    Kris

     

     

     

     

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    I really appreciate your detailed follow up. Here are my results. Issue still present: 

     

    1. Dropdown Items Property set to: 
      1. [" ", "Completed", "Completed w/ Comments", "Exceptions Taken"]
         
      2. 0.png
    2. Error message is present with Text Property set to Parent.Error
      1. 1.png
    3. Data Card Update Property set to: (I need to report Comments if they are added)
      1. Concatenate(
         prejobSafetyChecklist_input.Selected.Value, 
         "; ", 
         If(
         IsBlank(
         prejobSafetyChecklistComments_input.Text), "No comments", prejobSafetyChecklistComments_input.Text))
      2. 2.png
    4. Data Card Required Property set to True
      1. 3.png

    Execute SubmitForm(formName) and no Error Message is displayed for the Data Cards in Question (there are 14 of them). The first 9 Data Cards error out just fine. But cards 10-24 do not error. 

     

    Its almost like the " " option is being seen as a text value.  I've tried "" and Blank() as options as well. No Go.

    4.png

     

    If I slap a new version of the Data Card in and mark it Required, it errors out no problem. 

    5.png

    If I copy in the dropdown menu AND leave the Update property to dropdown_1.Selected.Value, everything errors out correctly. 

    6.png

    If I try to copy over the comment box and change the Update Function, NO GOOD, error message disappears.

     

    What is wrong with my UPDATE Function where it overrides the REQUIRED Function of the Data Card?

    7.png

     

  • mwilsontx64 Profile Picture
    2 on at

    I know this is 6 years late, but it may help someone in the future. I believe your update statement is always returning a non-blank value even if prejobSafetyChecklist_input and prejobSafetyChecklistComments_input are blank. If these fields are blank, Concatenate() will return "; no comments" which passes the Required validation. The Update should be changed to:

    If(
    	IsBlank(prejobSafetyChecklist_input.Selected.Value), 
    		prejobSafetyChecklist_input.Selected.Value, 
    		Concatenate(
     			prejobSafetyChecklist_input.Selected.Value, 
     			"; ", 
     			If(
     			IsBlank(
     				prejobSafetyChecklistComments_input.Text), "No comments", prejobSafetyChecklistComments_input.Text)))

     

    so that it only concatenates the values if the drop-down has a value.

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the April Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
Vish WR Profile Picture

Vish WR 893

#2
Valantis Profile Picture

Valantis 571

#3
11manish Profile Picture

11manish 482

Last 30 days Overall leaderboard