Dictionary (of Integer , List(of integer))

Want to create Dictionary in uipath to store integer as key and list of integer as value. but i am facing error in the process of assigning value as list, can anyone suggest any way

Hi,

Hope the following helps you.

if the above doesn’t work for you, can you elaborate your issue?

Regards,

Thnaks for your reply. i will try this and reply to you.
can you please clarify,
listToAdd = ? what you pass as value inside this variable.

Hi,

The above is the following.

dict = New Dictionary(Of Int32, List(Of Int32))From{{1,New List(Of Int32)From{1,1}}}
listToAdd = New List(Of Int32)From{2,2}
dict(2) = listToAdd

Regards,

If I try to output dictionary value for a particular key then getting output as:
“System.Collections.Generic.List`1[System.Int32]”

Screenshot (12)

Hi,

Can you try the following expression?

String.Join(",",dict(1))

Or

Set breakpoint and run debug mode. See value at locals panel when workflow stops there.

Regards,

Hii

It worked. Thanks for your support

1 Like

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