JSON Parse

Hi Everyone,

[
[{
‘abc’: ‘4587864958’,
‘def’: ‘3745y7385’,
‘gty’: ‘3478535’,
‘oop’: ‘3458349’,
‘mmn’: ‘3478535’
},

{
‘abc’: ‘4587864958’,
‘def’: ‘3745y7385’,
‘gty’: ‘3478535’,
‘oop’: ‘3458349’,
‘mmn’: ‘3478535’
},

{
‘abc’: ‘4587864958’,
‘def’: ‘3745y7385’,
‘gty’: ‘3478535’,
‘oop’: ‘3458349’,
‘mmn’: ‘3478535’
}]]

this is my Jtoken variable “jtoken_inf”. I want to access the abc value in the first row, how do I do this?

Try this

1 Like

Hi @happyautomaion

Try this:

jtoken_inf.SelectToken("[0].abc").ToString()

Regards

Exception has been thrown by the target of an invocation. I get this error

jtoken_inf.List.SelectToken(“[0].[‘abc’]”) when i try this its return null

Hi @happyautomaion
Try this:

 jtoken_inf[0][0]["abc"].ToString()

Regards

Hi @happyautomaion

Try this

jtoken_inf(0)('abc')

Hope it helps!!

1 Like

Hi,

When i use deserialize json array before this assign, it works. Thank a lot!

1 Like

@happyautomaion

Welcome.Happy Automation.

1 Like

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