iOS Question download a html and save it to a string

Discussion in 'iOS Questions' started by Rumin, Dec 28, 2017.

  1. Rumin

    Rumin Member Licensed User

    Now I'm writing code for IOS as follows:

    private NameToCode as string
    dim job1 as HttpJob
    searchnamestrURL="http://quote.eastmoney.com/stocklist.html"
    job1.Initialize("job1",Me)
    job1.Download(searchnamestrURL)

    If job.Success=True Then
    Select job.JobName
    Case "job1"
    NameToCode=job.GetString2("GB2312")
    Case "job2"
    strRetrived=job.GetString2("GB2312")
    Case "job3"
    p2strRetrived=job.GetString2("GB2312")
    End Select
    Else
    NameToCode="nothing"
    End If

    It crushed. When I change the URL as searchnamestrURL="http://hq.sinajs.cn/list=sh600583", it was ok. All the difference is the former downloaded string is large in size and the latter is small. I had written the same codes with my b4a, no any problem. Who can tell me why? Thanks in advance.
     
  2. Erel

    Erel Administrator Staff Member Licensed User

    Please use [code]code here...[/code] tags when posting code.

    Please post the error message.
     
  3. Rumin

    Rumin Member Licensed User

    Erel, No error message just crush. I used my iphone 4.
     
  4. Erel

    Erel Administrator Staff Member Licensed User

    Can you upload a small project with the relevant code?
     
  5. Rumin

    Rumin Member Licensed User

    Hi Erel,
    Happy New Year!
    I don't know how to upload yet. I plan to change to using macOS computer to see if the error happens.
     
  6. Erel

    Erel Administrator Staff Member Licensed User

    File - Export as zip and then upload the created zip file.
     
Loading...
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice