thinghttp json parse string get more value.
3 次查看(过去 30 天)
显示 更早的评论
I want to get 2-3 of the results at once using parse string in thingHTTP. Is it possible?
I can get 1 value using PArse string, but I want to get several values together. I want to get date and time together from the results in this example.
Results is :
{ "date": "03-18-2023", "milliseconds_since_epoch": 1679147976499, "time": "01:59:36 PM" }
How can I write parse string box in thinghttp?
Thanks
2 个评论
采纳的回答
Sachin
2023-3-23
Hi
I understand that you want more values using parse string in thinghttp.
I assume that your URL response is JSON. Since you want to get multiple values at once So I suggest[AK1] you to use the ‘webread’ function in MATLAB. This function will help you to get all the JSON object values at once.
webread('your url')
This will return a struct with fields.
For more information about ‘webread’ refer to:
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 JSON Format 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!