> For the complete documentation index, see [llms.txt](https://help.pickzen.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://help.pickzen.com/developers/sdk/howtos/populate-custom-dropdown.md).

# Populate custom dropdown

Say you have a default dropdown with predefined values:

<figure><img src="/files/MUpxipPBxgOIKfDL5Fmn" alt=""><figcaption></figcaption></figure>

We could define in the slide settings the following information:

<figure><img src="/files/iBEnTedmg4R3AZvxTZRj" alt=""><figcaption></figcaption></figure>

This way, we can use the SDK to populate this information based on any condition. For example the colors defined in the slide metadata:

```
function Form() {
    const { slideModel } = useContext(SlideContext);

    let field = slideModel.getFieldById(105);
    field.removeOptions();
    slideModel.getMetaValue('colors').forEach(o => field.addOption(o.id, o.title));

    return (
        <FormFields fields={slideModel.getFields()} />
    );
}
```

The result will be:

<figure><img src="/files/Syr1cPxXjd3MtbsW7Qji" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/gxA3Mjkw1n1OCXUdlv3J" alt=""><figcaption></figcaption></figure>
