Android Question [SOLVED] Is this a JSON string? How to parse it?

incendio

Well-Known Member
Licensed User
Longtime User
Hi guys,

I am new to JSON, got this string, not event sure if this is a JSON string type.
B4X:
{"chart":{"result":[{"meta":{"currency":"USD","symbol":"GOOGL","exchangeName":"NMS","instrumentType":"EQUITY","firstTradeDate":1092922200,"regularMarketTime":1671570004,"gmtoffset":-18000,"timezone":"EST","exchangeTimezoneName":"America/New_York","regularMarketPrice":89.02,"chartPreviousClose":95.07,"priceHint":2,"currentTradingPeriod":{"pre":{"timezone":"EST","start":1671526800,"end":1671546600,"gmtoffset":-18000},"regular":{"timezone":"EST","start":1671546600,"end":1671570000,"gmtoffset":-18000},"post":{"timezone":"EST","start":1671570000,"end":1671584400,"gmtoffset":-18000}},"dataGranularity":"1d","range":"","validRanges":["1d","5d","1mo","3mo","6mo","1y","2y","5y","10y","ytd","max"]},"timestamp":[1671114600,1671201000,1671460200,1671546600],"indicators":{"quote":[{"open":[93.12999725341797,90.76000213623047,90.26000213623047,88.11000061035156],"high":[93.63999938964844,91.33000183105469,90.55999755859375,89.18000030517578],"low":[90.01000213623047,89.5199966430664,88.20999908447266,87.44000244140625],"volume":[40107000,58000200,29493000,23402800],"close":[90.86000061035156,90.26000213623047,88.44000244140625,89.0199966430664]}],"adjclose":[{"adjclose":[90.86000061035156,90.26000213623047,88.44000244140625,89.0199966430664]}]}}],"error":null}}

That string is a Google's stock data from Yahoo Finance.

From that string, want to get values of high, low, open, adjclose, & volume.

Any hints to parse that string into needed values?
 
Top