given below iis a dummy data in string format :[
{
““Name””: ““ABC””
},
{
““Name””: ““EFGH””
},
{
““Name””: ““IJKL””
}]"
I want output in array of {“ABC”,“EFGH”,“IJKL”}
how i can get this output?
given below iis a dummy data in string format :[
{
““Name””: ““ABC””
},
{
““Name””: ““EFGH””
},
{
““Name””: ““IJKL””
I want output in array of {“ABC”,“EFGH”,“IJKL”}
how i can get this output?
1/ deserialize to JArray
2/ yourArray = JArray.Select(function(x) CType(x.First, JProperty).Value.ToString ).toarray
cheers
The string you have is JSON String. Use 3 assign activities as below.
jsonString = "[{""Name"": ""ABC""}, {""Name"": ""EFGH""}, {""Name"": ""IJKL""}]"
jsonObject = JsonConvert.DeserializeObject(Of JArray)(jsonString)
namesArray = jsonObject.Select(Function(x) x("Name").ToString()).ToArray()
Hi @Aditi0374
Deserialize JSON Array’ Activity
jsonString Your StringJArrayIn the last assign
nameArray = JArray.Select(Function(item) item("Name").ToString()).ToArray()
Hope this helps ![]()