why I got error at this DownloadManager Method in android？
<p>I tried to make an update check at the loading page of my app, but I keep getting this awful error at  File file = DownloadManager.getFileFromServer(info.getUrl(), pd); </p>

<pre><code> public void run() {  
            try {  
                File file = DownloadManager.getFileFromServer(info.getUrl(), pd);  
                sleep(3000);  
                installApk(file);  
                pd.dismiss();   
            } catch (Exception e) {  
                Message msg = new Message();  
                msg.what = DOWN_ERROR;  
                handler.sendMessage(msg);  
                e.printStackTrace();  
            }  
        }}.start();  
}  
</code></pre>

<p>and at the parser info =  UpdataInfoParser.getUpdataInfo(is);</p>

<pre><code> public void run() {  
        try {  

            String path = getResources().getString(R.string.serverurl);  

            URL url = new URL(path);  
            HttpURLConnection conn =  (HttpURLConnection) url.openConnection();   
            conn.setConnectTimeout(5000);  
            InputStream is =conn.getInputStream();   
            info =  UpdataInfoParser.getUpdataInfo(is);  

            if(info.getVersion().equals(versionname)){  
                Log.i(TAG,"版本号相同无需升级");  
                LoginMain();  
            }else{  
                Log.i(TAG,"版本号不同 ,提示用户升级 ");  
                Message msg = new Message();  
                msg.what = UPDATA_CLIENT;  
                handler.sendMessage(msg);  
            }  
        } catch (Exception e) {  
            // 待处理   
            Message msg = new Message();  
            msg.what = GET_UNDATAINFO_ERROR;  
            handler.sendMessage(msg);  
            e.printStackTrace();  
        }   
    }  
</code></pre>

<p>PS  updateInfo is an unique class like below</p>

<pre><code>public class UpdataInfo {  
private String version;  
private String url;  
private String description;  
public String getVersion() {  
    return version;  
}  
public void setVersion(String version) {  
    this.version = version;  
}  
public String getUrl() {  
    return url;  
}  
public void setUrl(String url) {  
    this.url = url;  
}  
public String getDescription() {  
    return description;  
}  
public void setDescription(String description) {  
    this.description = description;  
}  
</code></pre>

<p>}  </p>

<p>Anybody could help me ? I am really stucked here for a week!!
You can just offer me another way to check update by xml file at the server, thanks</p>
