开发者

Get integer from UIWebView

开发者 https://www.devze.com 2023-03-31 07:05 出处:网络
I have a webpage that outputs an integer that I need to parse. I know how to get a string from a website in an UIWebView, but I need to get it as an integer. Converti开发者_C百科ng a string to an inte

I have a webpage that outputs an integer that I need to parse. I know how to get a string from a website in an UIWebView, but I need to get it as an integer. Converti开发者_C百科ng a string to an integer using [myString integerValue] won't work here. How can I do this?

Edit: Here is my error

Get integer from UIWebView


The reason behind the warning is that your variable is not an integer, but a pointer to an integer.

NSInteger *test = [onlineUsers integerValue];
          ^
 Get rid of the asterisk
0

精彩评论

暂无评论...
验证码 换一张
取 消