If you have 10,000 rows of data in JSON, I’m not sure exchanging it through oBrowser is the best solution. Omnis character variable max out at a length of 100,000,000 so it’s possible you’d exceed that buffer.
This is where you might want to query your data source directly from Omnis using its REST client or straight HTTP calls and OJSON. oBrowser is for displaying visual data. If you want to have buttons, links, or other visual elements that trigger data processing in Omnis, use oBrowser. Send unique tokens or values on those buttons to Omnis to build the URL to the remote data source…or just pass the URL directly with a
_new target and intercept it in
As to sending data back to the HTML page, that entirely depends on where the HTML is being sourced. If it’s served up from a web server you can send data from Omnis via URL parameters when you reload the page. For example, if I have
https://mysite.com and want to send a string from Omnis, you could do something like this:
Calculate $cinst.$objs.oBrowser.$urlorcontrolname as con("https://mysite.com?omnis_data=",OWEB.$escapeuritext(icString))
Note the call to URL-escape the string to handle spaces or other special characters.