[Qt-interest] QtNetwork
Murphy, Sean M.
sean.murphy at gd-ais.com
Mon Nov 23 17:02:53 CET 2009
> I'm here again with a noob problem :D
> I'm developing a game in Qt using XCode 3.2.1 and I'm not able to
> understand how the QtNetwork module works. I mean: I want my software
> checks at the start if there are updates available so I use QHttp and
> QUrl to download the version file. To do this I've added the code:
>
> #include <QtNetwork>
>
> in the file where I use QHttp and QUrl and the code:
>
> QT += network
>
> in the .pro file. Then I try to build and run with XCode button but
> the compiler returns the error: "QtNetwork: no such file or
> directory". It returns also all the errors connected to the classes in
> the QtNetwork module (i.e. QHttp with no type and so on).
XCode doesn't understand .pro files, it works on it's own project files
(I think .xcode?). So when you make changes to the .pro file, those
changes do not have any effect on XCode's build. You need to re-run the
qmake command that creates an XCode project from a Qt .pro file.
That being said, you should really look into using Qt Creator for doing
Qt development. It naturally understands .pro files, and works on all
platforms!
Sean
More information about the Qt-interest-old
mailing list