---
title: "Create a custom cascading dropdown field"
canonical: "https://support.appfire.com/space/PSJ/15482650/Create%20a%20custom%20cascading%20dropdown%20field"
format: markdown
---
> Macro (aura-html)


# Problem

When creating a predefined cascading select field, the option in the first dropdown list reflects the values available in the second dropdown list. However, in reporting, the values are combined into a single one. This can restrict the JQL used for filtering. Also, the field only allows users to select a single value in one or both fields.

# Solution

You can solve this problem using Power Scripts™ Live Fields. For details on accessing the current screen with Live Fields, go to our [documentation](https://appfire.atlassian.net/wiki/spaces/PSJ/pages/15488008).

For the purpose of this example, consider a combination of two fields: **Select Lis****t 1** (single choice) and/or **Select Lis****t 2** (multiple choice). 

The fields have the following options:

| Select List 1 (customfield_XXXXX) | Select List 2 (customfield_YYYYY) |
| --- | --- |
| - Option 1
- Option 2
- Option 3 | - 1A
- 1B
- 1C
- 2A
- 2B |

The below scripts configures the fields to allow for only the following option combinations:

- Option 1
  - 1A
  - 1B
  - 1C
- Option 2
  - 2A
  - 2B
- Option 3

##### **liveField.sil**

```java
lfInstantHook({"customfield_XXXXX", "customfield_YYYYY"}, "hook.sil");
lfWatch("customfield_XXXXX", {"customfield_XXXXX", "customfield_YYYYY"}, "hook.sil", {"change"});
```

##### **hook.sil**

```java
string v = argv["customfield_XXXXX"];

if (v == "Option 1") {
    lfAllowSelectOptions("customfield_YYYYY", {"None", "1A", "1B", "1C"});
} else if (v == "Option 2") {
     lfAllowSelectOptions("customfield_YYYYY", {"None", "2A", "2B"});
} else {
     lfAllowSelectOptions("customfield_YYYYY", {"None"});
}
```

These scripts render the following result.

![image](media://1eb34f6b-8442-43f7-a5b9-422505e342f1)