On Tuesday 18 April 2006 00:22, Alvaro Arenas wrote:
> Hi.
>
> I am trying to use the kURLRequester widget (this comes with the
> qt-designer) but this widget is not recognised. I guess I should add
> some include line like import kde. But I wonder why qt-dessigner
> doesn't add the code by itself. By the way I am using this because I
> want to open a dialog requesting for the path to a directory.
>
> I know this is a very basic question but I haven't found an
> appropriate tutorial for pyqt (pykde)
>
> Thanks
>
> Alvaro
>
> PD: Here is the error:
>
>
> [EMAIL PROTECTED]:~/Projects/qtProject2$ python myFirstApp.py
> Traceback (most recent call last):
>   File "myFirstApp.py", line 7, in ?
>     f = CustomForm1()
>   File "/home/aarenas/Projects/qtProject2/customForm1.py", line 7, in
> __init__ Form1.__init__(self)
>   File "/home/aarenas/Projects/qtProject2/form1.py", line 53, in __init__
>     self.kURLRequester1 = KURLRequester(self,"kURLRequester1")
> NameError: global name 'KURLRequester' is not defined

The KURLRequester class is in the kfile module - it looks like you're not 
importing kfile.

If you're using pyuic or kdepyuic to generate Python code, you'll probably 
need to add an 'import kfile' manually.

Jim

_______________________________________________
PyKDE mailing list    [email protected]
http://mats.imk.fraunhofer.de/mailman/listinfo/pykde

Reply via email to