Discussion Board

Results 1 to 3 of 3
  1. #1
    Registered User roguel6's Avatar
    Join Date
    Jan 2011
    Posts
    12
    Hi!

    I am developing an app for Symbian with Qt where you can download some files.

    I use QNetworkRequest and QNetworkReply.

    It works fine in N97 but I got this error ("CActiveScheduler::RunIfReady() returned error: -4") in N8 after downloading several files, appearing in the screen the next message too: "Memory full, close some apps and try again."

    However, I am writing to the file every time I receive some data with the readyRead() signal, so the memory shouldn't be full. Here I attached the code used.

    Code:
     //sets the requested url
        QUrl url (url_string);
        qDebug ("Starting download...");
        download_canceled = false;
    
        //init request
        QNetworkRequest request;
        request.setUrl(url);
    
        QNetworkAccessManager* netManager = new QNetworkAccessManager (this);
        //connect (netManager, SIGNAL (finished (QNetworkReply*)),this,SLOT(replyFinished (QNetworkReply*)));
        reply = netManager->get(request);
        connect(reply, SIGNAL(error(QNetworkReply::NetworkError)), SLOT(replyError(QNetworkReply::NetworkError)));
        connect(reply, SIGNAL(finished()), SLOT(on_download_finished()));
        connect(reply, SIGNAL(downloadProgress(qint64, qint64)), SLOT(on_receivingProgress(qint64, qint64)));
        connect(reply, SIGNAL(readyRead()),SLOT(downloadReadyRead()));
    And I have the following code in the readyRead() slot:

    Code:
    void NokiaBridge::downloadReadyRead()
    {
        file.write(reply->readAll());
    }
    Thank you so much!

  2. #2
    Regular Contributor negus's Avatar
    Join Date
    Aug 2008
    Posts
    95
    Try to change TARGET.EPOCHEAPSIZE in your .pro file.

    I use for big file download this values:

    TARGET.EPOCHEAPSIZE = 0x020000 0x8000000

  3. #3
    Registered User roguel6's Avatar
    Join Date
    Jan 2011
    Posts
    12
    Thanks! It seems to work like a charm! solved!

Similar Threads

  1. Replies: 9
    Last Post: 2008-03-06, 18:37
  2. 6230: "invalid file" while downloading application.
    By Wontar in forum Mobile Java General
    Replies: 1
    Last Post: 2006-12-13, 18:03
  3. "Invalid file" error message while downloading game on my nokia 40 series
    By dotcdotc in forum Mobile Web Site Development
    Replies: 1
    Last Post: 2003-12-30, 10:24
  4. Replies: 0
    Last Post: 2003-06-19, 17:39

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Nokia Developer aims to help you create apps and publish them so you can connect with users around the world.

京ICP备05048969号  © Copyright Nokia 2013 All rights reserved