开发者

QnetworkReply error - Symbian Qt

I have the following piece of code.

  QNetworkAccessManager *man = new QNetworkAccessManager(this);

    QNetworkRequest getRequest;
开发者_如何学C    getRequest.setUrl((QUrl)requestUrl);

    m_svcReply = man->get(getRequest);
    connect(m_svcReply, SIGNAL(finished()),this, SLOT(getWebRequestFinished()));
    connect(m_svcReply, SIGNAL(error(QNetworkReply::NetworkError)),this, SLOT(webrequestFailed(QNetworkReply::NetworkError)));

If I'm executing this request over WIFI, I get a proper response from the server. However if I'm executing this request over 3G, I get a protocol "" is unknown error.

Any ideas why this might be happening?

Thanks


Have you added the NetworkServices capability to your app?

NetworkServices is a Symbian capability which grants access to remote services (such as dialing a number or sending a text message, WLAN, GPRS), which might incur a cost for the mobile device user.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜