Quantcast
Channel: Questions in topic: "httpwebrequest"
Viewing all articles
Browse latest Browse all 190

WWW yield is not returning any value in ios for yahoo finance api

$
0
0
Hi All, I am getting the stock value from yahoo finance and displaying it in a Text UI component. The below code is working fine in Windows PC, Mac, Android mobile but not in iOS. Code is not getting executed after " yield return wwwEricA;" only for yahoo finance http link "http://finance.yahoo.com/d/quotes.csv?s=ERIC-A.ST&f=sl1d1t1c1p2ohgv&e=.csv" . For testing i have given "https://www.google.co.in/" and that is returning value in ios mobile also. So i guess the problem is only with that particular yahoo URL but could not find what is that. Please help me to solve this issue. Code : public Text EricAStockText; private WWW wwwEricA; private string stockUrlEricA; private string[] stockArrayEricA; private char[] seperators = { ',' }; void Start() { stockUrlEricA = "http://finance.yahoo.com/d/quotes.csv?s=" + WWW.EscapeURL("ERIC-A.ST&f=sl1d1t1c1p2ohgv&e=.csv"); StartCoroutine(GetStockValueA(stockUrlEricA)); } private IEnumerator GetStockValueA(string URL) { wwwEricA = new WWW(URL); yield return wwwEricA; stockArrayEricA = ParseStockValue(wwwEricA.text, seperator); EricAStockText.text = stockArrayEricA[1]; } private string[] ParseStockValue(string valueString, char[] seperator) { return valueString.Split(seperator, System.StringSplitOptions.RemoveEmptyEntries); }

Viewing all articles
Browse latest Browse all 190

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>