Select Case, Switch case

Hi there, hope you’re doing great!

I come with a question regarding New UiPath Apps framework (I’m currently migrating ALL):

I have several dropboxes that shows me different lists depending on the selected value.
image
In Legacy, I managed to show each list by a nested if like
image
I want to simplify and, since we can use VB expressions, I wonder… How can we use a Switch, a Select Case?
I’ve tried with VB but It is not recognized:
image

image

@Arvind_Kumar1 Did you find any situation like this one? Any feedbak will be more than welcome :blush:
Thanks in advance family,
HUG!

@jmedinacarbonell ,

Do you have two entity separated for Phone standard and and phone smartphone ?

Thanks,
Arvind

Hi, thanks for your help!

Yes, I have actually several ones so, depending on the Category, I want to show the selected list, let me picture an example:

I have 2 dropdowns, first for categories and second for selected category items:

  • List of categories

    • List_Categories: {“Phone”, “Car”}
  • For each category, I have several items

    • List_Phone: {“Samsung”, “Google”}
    • List_Car: {“Ford”, “Opel”}

So, I have a drop-down showing the list of categories. Then, depending on what I select in the first one, I show the selected category items. In this case, if I select “Phone”, second drop-down should show “Samsung”, “Google”

@jmedinacarbonell ,

OK great, Please create a new entity for Category type and in to category type you can make a relationship between category.

Once above is done on Entity level please follow below on UI side.

  1. Go to Category type Dropdown
  2. Click on List source
  3. Select Query Builder
  4. Select Category type source into Query builder
  5. Apply filter on that
  6. Left side field name from category type = Category Dropdown.selectvalue
  7. Save Query

Test it, Result will change automatically on selection.

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.