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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Validate combobox for ...
Power Apps
Unanswered

Validate combobox for default selected items is not blank

(0) ShareShare
ReportReport
Posted on by 2

I am trying to validate the combobox default selected items,

When they select the items in the new form, they are concatenated and stored in the form of string in SQL column,

and when they try to edit that, it is split from a label as default selected items and it displays the default list.

 

When in the edit form, I am not able to validate the comboxbox though. Since it just validates for selected items and not default selected items.

 

Can anyone help me out on how to check if the combobox is null for default selected items?

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

    Hi @chaitanyaChavan,

    Do you want to check if the Default selected items of the Combo box control is blank?

    How do you set the DefaultSelectedItems property within the Combo box control?

     

    If you want to check if the Default selected items of the Combo box control is blank, I have made a test, please take a try with the following workaround:8.JPG

     

    9.JPG

    Set the DefaultSelectedItems property of the Combo box control to following formula:

    If(
     EditForm1.Mode=FormMode.New,
     {
     '@odata.type':"#Microsoft.Azure.Connectors.SharePoint.SPListExpandedReference",
     Value:"Default Value" /* <-- Set default value */
     },
     Parent.Default
    )

    Set the Text property of the Label control to following formula:

    DataCardValue5.Selected.Value

    Note: The DataCardValue5 represents the Combo box control within my Edit form.

    If you have set the DefaultSelectedItems property of the Combo box control as I mentioned above, then when you open a new form, you could use the following formula to check if the Default selected items is blank:

    If(IsBlank(DataCardValue5.Selected.Value),"Blank","Not Blank")

    The GIF screenshot as below:Test1.gif

     

    More details about set a Default value for a Choice type column of SP list within Edit form, please check the following thread:

    https://powerusers.microsoft.com/t5/General-Discussion/Set-default-value-for-a-drop-down-in-a-new-form/td-p/82924

    Please also check and see if the following blog would help in your scenario:

    https://powerapps.microsoft.com/en-us/blog/default-values-for-complex-sharepoint-types/

     

    Best regards,

    Kris

     

     

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 796 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 327 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard