Convert an Object to Dictionary

Hello,
I have an object which is obtained as an item from a datatable column. this column’s respective row value is retrived in a loop.
For Each Row

ForEach row in datatable
row(“abcColumn”) to get the value

I need to change row(“abcColumn”) which is a System.Object to a New Dictionary(of String,String) type.

abcColumn in the datatable is of type Dictionary(of String,String)

Can you pleas help me with this?

Dear @PK-SANKAR,

Please have a look a the attached workflow. please mark as solution if found useful.
Thank you

Excel Test.zip (21.4 KB)

In my case row(“columnname”) is dictionary type inside the data table. But when i use it in the for loop i need to assign this row(“columnname”) to a Dictionary variable.

@PK-SANKAR
can you please share some sample rows. This makes your requirement more clear. Thanks

I am adding this dictionary datatype column into table dynamically using Add Data Column.

Hello @PK-SANKAR,

I don’t know if it will do but it’s worth trying:

TryCast(row("abcColumn"), Dictionary(Of String, String)

3 Likes

Great!! it worked… Thank you : :slight_smile:

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