Please try this assign. With this assign, “010” is key and “gesperrt” is the value. Please change the double quotes, when you copy this statement to your workflow.
New Dictionary(Of String,String)From{{“010”,“gesperrt”},{“in Erstellung”,“im Hintergrund”},{“in Bearbeitung”,“fehlerhaft”}}
But I meant that I already have the value in my string variable “DictStatusWert”.
I want to convert the String Variable “DictStatusWert” to my Dictionary(Of String, String()) “DictStatus” in an Assign-Activity
I have the value: New Dictionary(Of String,String())From{{“010”,{“gesperrt”,“in Erstellung”,“im Hintergrund”,“in Bearbeitung”,“fehlerhaft”,“neu”}}} in a Excel Cell.
I read it with a read cell value activity and save it to the string variable “DictStatusWert”.
After that I want to work with my Dictionary(Of String, String()) “DictStatus”. Before that, I want to convert my String Variable to my Dictionary(Of String, String()).
For example:
Assign to: DictStatus
Assign From: DictStatusWert.toDictionary(Of String, String()).
But this syntax isn’t working for me, because the follwing error appears:
Overload resolution failed because no accesible ‘ToDictionary’ accepts this number of arguments.
Close, but I dont want to get any value from the dictionary.
Maybe I misunderstood the syntax “toDictionary”.
In general, I just want to fill in the default value out of my excel cell to DictStatus
I have the value: “New Dictionary(Of String,String())From{{“010”,{“gesperrt”,“in Erstellung”,“im Hintergrund”,“in Bearbeitung”,“fehlerhaft”,“neu”}}}” in a Excel Cell.
I read it with a read cell value activity and save it to the string variable “DictStatusWert”.
After that I want to work with my Dictionary(Of String, String()) “DictStatus”. Before that, I want to convert my String Variable to my Dictionary(Of String, String()).
So that my Dictionary “DictStausWert” has the Default Value:
New Dictionary(Of String,String())From{{“010”,{“gesperrt”,“in Erstellung”,“im Hintergrund”,“in Bearbeitung”,“fehlerhaft”,“neu”}}}
when this string from excel
“New Dictionary(Of String,String())From{{“010”,{“gesperrt”,“in Erstellung”,“im Hintergrund”,“in Bearbeitung”,“fehlerhaft”,“neu”}}}”
should be used as VBCode code then you are blocked as compiling cannot be bypassed
How about:
stroring dictionaray as JSON String "{'010':['gesperrt','in Erstellung','im Hintergrund','in Bearbeitung','fehlerhaft','neu']}"
That worked.
But what If I have more value in my excel cell like the following:
New Dictionary(Of String,String())From{{“010”,{“gesperrt”,“in Erstellung”,“im Hintergrund”,“in Bearbeitung”,“fehlerhaft”,“neu”}},{“100”,{“Blokov.”,“ve zpracování”,“Na Pozadí”,“ve zpracování (in work)”,“Chybné”,“Nové”}}}
→
When I change it into this:
{‘010’:[‘gesperrt’,‘in Erstellung’,‘im Hintergrund’,‘in Bearbeitung’,‘fehlerhaft’,‘neu’]},{‘100’:{‘Blokov.’,‘ve zpracování’,‘Na Pozadí’,‘ve zpracování (in work)’,‘Chybné’,‘Nové’}]
It does not work, because "the additional text encuntered after finished reading JSON content: ,.Path “, line 1, position 89”