Showing results for 
Search instead for 
Did you mean: 
Helper II
Helper II

Row not to appear if empty

Hi, could you help me with transforming codes I already have? I would need rows on my list (code 1) and in the table (code 2) not to appear if there is nothing chosen in the combo box.  So something like "If Blank, then do not appear". And this should be never applied for the first in table/firs point on the list as it is a must to fill at least one to create a ticket. 2 and 3 are optional. 


Attached simple - as is and as it should be 🙂




    "<li> "&Concatenate(Concat(xxxCode.SelectedItems,xxx_x0020_Code_x0020_ID,";")," for: ", Concat(Country.SelectedItems,CountryCode,";"))&" </li>"&
    "<li> "&Concatenate(Concat(xxxCode_1.SelectedItems,xxx_x0020_Code_x0020_ID,";")," for: ", Concat(Country_1.SelectedItems,CountryCode,";"))&" </li>"&
    "<li> "&Concatenate(Concat(xxxCode_2.SelectedItems,xxx_x0020_Code_x0020_ID,";")," for: ", Concat(Country_2.SelectedItems,CountryCode,";"))&" </li>"&
"<table width='100%' border='1'cellpadding='5' style='border: 1px solid black;border-collapse:collapse'>"& 
"<tr style='background-color:#efefef'>
    <th>Id</th> <th>Job codes</th> <th>Country</th><th>Submitter</th>"&
    "<tr><td> "&1&"</td><td>"&Concatenate(Concat(xxxCode.SelectedItems,xxx_x0020_Code_x0020_ID,";")," </td><td> ", Concat(Country.SelectedItems,CountryCode,";"),"</td><td rowspan=3>", SubmittersName.Text )&" </tr></td>"&
    "<tr><td> "&2&"</td><td> "&Concatenate(Concat(xxxCode_1.SelectedItems,xxx_x0020_Code_x0020_ID,";")," </td><td> ", Concat(Country_1.SelectedItems,CountryCode,";"))&" </tr></td>"&
    "<tr><td> "&3&"</td><td>"&Concatenate(Concat(xxxCode_2.SelectedItems,xxx_x0020_Code_x0020_ID,";"),"</td><td> ", Concat(Country_2.SelectedItems,CountryCode,";"))&" </tr></td>"&
"</table>"& "<br></br>"&









Should be










Should be




Memorable Member
Memorable Member



Try adding If condition like below for each combo box entry:


If(!IsEmpty(xxxCode.SelectedItems.Value), "<li> "&Concatenate(Concat(xxxCode.SelectedItems,xxx_x0020_Code_x0020_ID,";")," for: ", Concat(Country.SelectedItems,CountryCode,";"))&" </li>")


Similarly add conditions for other combo box as well as table code.

Please click Accept as solution & 👍 if my answer helped you to solve your issue. This will help others to find the correct solution easily. If the answer was useful in other ways, please consider giving it ‌‌👍

Hi @ganeshsanap it does not work. I 'm getting an error that there are some unexpected characters now in the formula.

@Mickow ,


    "<li> "&Concat(xxxCode.SelectedItems,xxx_x0020_Code_x0020_ID&";")&" for: "& Concat(Country.SelectedItems,CountryCode&";")&" </li>"&
    If(!IsEmpty(xxxCode_1.SelectedItems.Value), "<li> "&Concat(xxxCode_1.SelectedItems,xxx_x0020_Code_x0020_ID&";")&" for: "& Concat(Country_1.SelectedItems,CountryCode&";")&" </li>")&
    If(!IsEmpty(xxxCode_2.SelectedItems.Value), "<li> "&Concat(xxxCode_2.SelectedItems,xxx_x0020_Code_x0020_ID&";")&" for: "& Concat(Country_2.SelectedItems,CountryCode&";")&" </li>")&


@gabibalaban Hey, well this code created like even more errors, 16 to be precise and I think this is because part of the original code (which is working perfectly) was dropped...

@Mickow ,

The idea was to understand the principle. It is hard to transpose here the formula exactly you needed.

There was a misspelling in my formula. Can you try it again ?

Does not work unfortunately. I will try to manipulate with the code later and let you know if I found some solution. 

Helper II
Helper II

Hi I think I found a partial solution, but have no idea why it is partial only. Could you help me please? My code looks now as below:

    "<li> "&Concatenate(Concat(xxxCode.SelectedItems,xxx_x0020_Code_x0020_ID,";")," for: ", Concat(Country.SelectedItems,CountryCode,";"))&" </li>"&
    If(IsEmpty(xxxCode_1.SelectedItems.xxx_x0020_Code_x0020_ID),"", "<li> "&Concatenate(Concat(xxxCode_1.SelectedItems,xxx_x0020_Code_x0020_ID,";")," for: ", Concat(Country_1.SelectedItems,CountryCode,";"))&" </li>")&
    If(IsEmpty(xxxCode_2.SelectedItems.xxx_x0020_Code_x0020_ID),"", "<li> "&Concatenate(Concat(xxxCode_2.SelectedItems,xxx_x0020_Code_x0020_ID,";")," for: ", Concat(Country_2.SelectedItems,CountryCode,";"))&" </li>")&

 And what I've noticed is that it does work for the second line, but not for the third one and the output looks like that:



I'm guessing that my syntax is incorrect somewhere between the first "If" and ending of the list...

It appears to me that there is no perfect solution and it is not about the code. I can tell that it is some deeper coding issue within PowerApps. I tried both: IsBlank and IsEmpty and both seem to work/not work in certain situations: IsBlank works fine when initially ComboBoxex are empty and there was no action taken on those (even chosen and cleared)...IsEmpty on the other hand works the opposite - it does what it should once something was chosen in the ComboBox and then cleared. This is all weird, but cannot find anything other explaining why it works for me like that. 

Helpful resources

Microsoft 365 Conference – December 6-8, 2022

Microsoft 365 Conference – December 6-8, 2022

Join us in Las Vegas to experience community, incredible learning opportunities, and connections that will help grow skills, know-how, and more.

Top Solution Authors
Top Kudoed Authors
Users online (1,579)