[PyKDE] newbie: QFileDialog
Paul Felix
pef at fluent.com
Wed Aug 28 15:39:01 BST 2002
> From: Eli Carter <eli.carter at inet.com>
>
> Ok, time for a dumb question. I've made a fleeting google attempt, and
> a cursory stroll through doc.trolltech.com/2.3 didn't turn up an answer.
>
> I want to use QFileDialog to let a user pick files on a remote system,
> such as over an ftp connection. I'm not really sure where to start. I
> expect to subclass it, but I don't know what internals would need to be
> overridden, where to find that out, or if that is possible in pyqt.
>
> A pointer to a discussion or documentation would be preferred, as this
> is something I expect I'll want to do more of in the future. (I want to
> learn the how's and why's so I can apply this in more than just this case.)
>
> TIA for any pointers,
>
Hi Eli,
I believe the answer is QUrlOperator. Try this:
from qt import *
from qtnetwork import *
qInitNetworkProtocols()
op = QUrlOperator("ftp://ftp.trolltech.com")
fd = QFileDialog()
fd.setUrl(op)
fd.exec_loop()
Paul
More information about the PyQt
mailing list