Solved

How can I add a published parameter that is multiple choice with alias with a tree?

  • 1 February 2020
  • 2 replies
  • 28 views

Userlevel 4
Badge +13

I want to create a published parameter that will give users the option of choosing multiple options from a dropdown/tree list, depending on the category.

 

I could use 'Choice with Alias (Multiple)' and then an AttributeValueMapper, but I'd rather not as the 'Choice (Multiple)' has the ability to 'Use Tree'

 

 

icon

Best answer by jlutherthomas 1 February 2020, 00:33

View original

2 replies

Badge +2

Hi @fmelizard,

 

 

You can do this by editing the configuration string in the Parameter Definition dialog. Add FME_DELIM:.% to the beginning of the configuration string.

 

You can change the '.' to be any delimiter you'd like (but ensure it's not present in any of your display or lookup values)

 

 

Start with 'Choice with Alias (Multiple)' and set up your configuration using your chosen delimiter value between node levels. At this point, if you use the dropdown for 'Default Value' and click 'Change Selection' it will look like this:

 

 

 

Now, add the FME_DELIM:.% to the beginning of the Configuration string:

 

 

You can see that the '.' delimiter has split my configuration values into different node levels and we can now use the tree view.

 

 

The % separates different choice options.

The , separates the display names from the values.

Badge +3

Hi @fmelizard,

 

 

You can do this by editing the configuration string in the Parameter Definition dialog. Add FME_DELIM:.% to the beginning of the configuration string.

 

You can change the '.' to be any delimiter you'd like (but ensure it's not present in any of your display or lookup values)

 

 

Start with 'Choice with Alias (Multiple)' and set up your configuration using your chosen delimiter value between node levels. At this point, if you use the dropdown for 'Default Value' and click 'Change Selection' it will look like this:

 

 

 

Now, add the FME_DELIM:.% to the beginning of the Configuration string:

 

 

You can see that the '.' delimiter has split my configuration values into different node levels and we can now use the tree view.

 

 

The % separates different choice options.

The , separates the display names from the values.

Hi @jlutherthomas,@fmelizard

I've got the same requirements, so thanks for posting this workaround. Your solution works well when defining the tree, as per my example below:

Clicking to select a default value brings up a tree view:

 

However, at run time, when we actually get the user to pick parameters, the tree view is not visible:

 

Is there something I'm missing, or is this expected behavour?

Thanks

Reply