Problem fetching XML file in Java

前端 未结 4 1138
感情败类
感情败类 2021-01-07 13:29

I am trying to use Google\'s unofficial weather API in an Android Application.

I use this code:

//get the text from the edit text
    userZip = zipCo         


        
4条回答
  •  旧巷少年郎
    2021-01-07 14:17

    Are you able to retrieve other URIs successfully?

    You could be hitting problems with the JVM configuration. In most environments I've come across, if your machine is configured so that the web browser can make HTTP requests successfully, then Java will also be able to make them successfully. But I've heard of special JVM configuration being needed when you're behind a proxy server, and I've no idea whether anything similar might be needed in an Android environment.

提交回复
热议问题