Skip to content

QtWS: Super Early Bird Tickets Available!

  • 0 Votes
    5 Posts
    379 Views
    P

    Thanks everyone

  • 0 Votes
    5 Posts
    867 Views
    KroMignonK

    @Vincent66 Bonjour, QTfp ne fait plus parti du project Qt mais les sources restes accessibles sur GitHub ==> https://github.com/qt/qtftp

    Pourquoi ne pas simplement partir de là et faire les adaptations eventuellement nécessaire pour la compilation?

  • 0 Votes
    5 Posts
    848 Views
    K

    @hakanaktan

    In your first post you have a connect to readyRead() that will be triggered most likely several times. If this is still there that might be the explanation that no data is available when finished is triggered. I suggest that you either way and the better is wait for finished signal.

  • 0 Votes
    11 Posts
    4k Views
    thamT

    About this project, I use the lib found on the github as I mentioned before. It works well and quite easy to adjust the codes for my own requirements.

    One bug I found about this lib is it do not delete the resource if clients disconnected(maybe not a big issue for the author so he did not fix it), you need to handle that part by yourself. If you need to have multiple keys, I suggest boost::multiindex, although the api is a bit complicated, it is easy to use and help us write clean codes.

    If my customers allowed, I would put the version after alternate to github.

  • 0 Votes
    13 Posts
    11k Views
    VRoninV
    #include <QCoreApplication> #include <QNetworkAccessManager> #include <QNetworkReply> #include <QNetworkRequest> int main(int argc, char *argv[]) { QCoreApplication a(argc,argv); QNetworkAccessManager netMan; QNetworkReply* const repl = netMan.get(QNetworkRequest(QUrl::fromUserInput(R"**(ftp://131.225.104.13/linux/.snapshot/NDMP_AUTO_SNAPSHOT3210/fermi/contrib/obsolete/video/nvidia/5328/NVIDIA.5328.README.txt)**"))); QObject::connect(repl,&QNetworkReply::readyRead,[repl]()->void{ qDebug().noquote() << repl->readAll(); }); QObject::connect(repl,QOverload<QNetworkReply::NetworkError>::of(&QNetworkReply::error),[repl]()->void{ qDebug() << "Error: " + repl->errorString(); }); QObject::connect(repl,&QNetworkReply::finished,repl,&QNetworkReply::deleteLater); QObject::connect(&netMan,&QNetworkAccessManager::authenticationRequired,repl,[repl](QNetworkReply *reply, QAuthenticator *authenticator)->void{ if(reply!=repl) return; aAuthenticator->setUser("MyUserName"); aAuthenticator->setPassword("MyPassword"); }); return a.exec(); }
  • 0 Votes
    3 Posts
    1k Views
    R

    @jsulm said in MDTM:Command not understood:

    ftp://115.111.229.10/21.05.2016.xls

    Thanks for replying, yes the url is working fine with wget

    wget ftp://username:password@(IP)/21.05.2016.xls

  • 0 Votes
    2 Posts
    932 Views
    SGaistS

    Hi and welcome to devnet,

    Did you try to access the server ? What did you try ?

  • 0 Votes
    9 Posts
    2k Views
    M

    @mrjj
    I could never figure out what was calling progressDialog. So after progress dialog was created, I did

    timer = new QTimer(this); timer->setSingleShot(true); timer->start(5000); connect(timer, SIGNAL(timeout()), this, SLOT(testing()));

    and

    void FtpWindow::testing() { progressDialog->hide(); }

    crude but it works. If there were a QDialog signal for isActiveWindow or hasAppeared, it would be better. But this works.

    Edit: ended up using progressDialog->setAttreibute(Qt::WidgetAttribute::WA_DontShowOnScreen, true);

  • 0 Votes
    2 Posts
    1k Views
    A

    Sorry for bringing this old thread back, but have you found a solution for sendig raw commands to the FTP?
    I am not able to use the old QFTP so i need this to get running with QNetworkAccessManager.
    Thanks in advance!

  • QT 5.5 - Working on FTP

    Unsolved General and Desktop
    9
    0 Votes
    9 Posts
    3k Views
    SGaistS

    By building and reading the documentation and taking a look at the example in the sources

  • Qt ftp on raspberry ...

    Unsolved QtonPi
    5
    0 Votes
    5 Posts
    2k Views
    M

    Perhaps it's the problem ! Thank's for your time lucas and your work !

  • 0 Votes
    15 Posts
    13k Views
    R

    I tried again to fix everything and now it is working.

    I made two big mistakes.

    I was not closing the files correctly. No I am waiting for the done()-signal and close the file. The documentation of QtFtp is a little bit confusing. I first understood that e.g. commandFinished() would always return the same number for a certain command like put or get. But this is not the case. With every scheduled and finished command you just get the number of the place in the schedule ;-)

    Thank you again for your help :-)