Display List of strings as Input option in Input dialog Box, using config file

How do I set a list of strings as an input option in the Input dialog box, But that list should be fetched from the config file?

use csv string with semicolon as delimiter
grafik

so put in your Config excel the list like: Option1;Option2;Option3

and retrieve it later from the Config(“YourKeyName”).toString

@Dimple_Mandal

Write the string value with comma separated in Config file. And then try below expression.

      Config("KeyName").ToString.Split(","c).ToList

and how where i use the above expression in inputdialog

@Dimple_Mandal

Set above expression to Option field in Input Dialog activity.

ok, thank you
,will try this



getting this error

do not mix up the two approaches
semicolon and field as described by me - Without Split Command
OR
comma and split command when using approach from @lakshman

I used one approach at one time,still getting same error

just show us the done implementation for first approach (Semicolon, Options String)


can you Upload a demo .Xaml ?

any reasons why outDT is used? Usually we do see for Config the Name Config for the dicitonary

grafik

So we would expect Field Options String = Config(“Name”).toString

For test purpose you can do also: Field Options String = “Options1;Options2;Options3;Options4”

@Dimple_Mandal

  1. Remove ToList from it.
  2. Names value separated with Semi-Colon in your config but you mentioned here comma in Split.


@Dimple_Mandal

It should be like this.

            outDt("Name").ToString(";"c)

Where Name value in config file will be - One;Two;Three;Four

More than 3 Values - Drop Down
2 or 3 Values - Radio button
1 - Text box

1 Like

If i put “Options1;Options2;Options3;Options4” directly to Input Option it works,
But if i use config(“Name”).toString then getting same error

comment failing acitvity out
put a breakpoint on this out commented activity
debug the bot - get Paused
Open immediate panel
TypeIn config and share with us the output

Thanks

Now how do i send these values to UIPath App dropdown, I am not able to get the data in uipath app dropdown,I dont want to hard code in App ,want to get the list that is set in Config file

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