- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
I have a dropdown list of country names. The selected country is placed in a parameter for use elsewhere.
However I would like the parameter to hold countryID instead of countryName, but still display the country name in the dropdown list.
I tried a a character format on countryID ('46' = 'Sweden') and set the dropdownlist to use countryID but the parameter then contains the formatted value so that didn't work.
Is there a way to do this?
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
I found that I could have the dropdown list displaying countryName and then add another dropdownList with countryID that is filtered by the first one (countryName and CountryID are in the same table).
The second one then sets a parameter containing the ID instead of the name.
I guess I'll try and hide the countryID -list somewhere...
It works reasonably well but I'd be interested in a better solution if anyone has one.
- Mark as New
- Bookmark
- Subscribe
- Mute
- RSS Feed
- Permalink
- Report Inappropriate Content
Which version of VA are you using. For numeric values you might be able to use a parameter that is filled with an expression. This expression can have a filter which can use a parameter.
So if you have 2024.05 or newer I would give it a try.