Split the values inside the json

Hi Guys,

I have a json like this i need the separate values in the array as a string. below is the format

[{“Year”:[“FY2019”,“FY2018”]},{“Month”:[“Jan (Oct)”,“Jul (Apr)”]}]

i need

FY2018
FY2019

Jan (Oct)
Jul (Apr)

like this i need it as a separate text…year and month in a different array…

help me out this thanks.

Suresh.

@suresh_kumar4 - pls try below -
add json.net package to your project
create a variable like jsonResult type as JObject
jsonResult = JObject.Parse(strJsonText) - assuming your above json text assigned to strJsonText.

jsonResult(“Year”)(0).ToString - will give you result as “FY2019”
jsonResult(“Year”)(1).ToString - will give you result as “FY2018”

jsonResult(“Month”)(0).ToString - will give you result as “Jan (Oct)”

1 Like

Thanks for your quick reply!! Let me try.