Dictionary<String,String> pathDictionary = new Dictionary(of String,???)
Please tell me how to define the"???".
thanks !
Hi,
Can you try the following expression?
dict = New Dictionary(Of String,String())
Regards,
Hi
Welcome to uipath forum
- Go to Variable panel and try creating like this
Variable name - dict_variable
Type as - click on browse for type and search for this
System.Collections.Generic.Dictionary(of string, string)
Default value as -
Without value
New Dictionary(of string, string)
With value
New Dictionary(of string, string) from {{“key1”,“value1”},{“key2”,“value2”}}
and if we want to add them once after creating a dicitonary variable then we can use ADD TO DICTIONARY ACTIVITY OR With a simple assign activity like this
dic_variable(“your keyname”) = “your value”
Cheers @zzzcoin
Did this work btw
Hi,
In my environment, it works as the following.
Which language do you use? The above is for VB.
Regards,
it works!thank you a lot!
Example of String Dictionary is : -
Suppose: USD - Us dollar, INR - Indian Rupee, EUR- Euro
Then its corresponding Dictionary will be initialised as -
Syntax:
new Dictionary(of string,string)from{{“USD”,“Us dollar”},{“INR”,“Indian Rupee”},{“EUR”,“Euro”}}