Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

at last I started a simple project (you tube video downloader) in quickly , But got stucked . I added youtube url entry dialog using quickly add dialog command and ;linked it to new button . How return url to the main window ? I don't have any previous experiance with python

My program now look like this

enter image description here

share|improve this question
up vote 2 down vote accepted

Depending on your code, you could do something like this:

url = None
dialog = UrlDialog()
response =
if response == Gtk.ResponseType.OK:
    url = dialog.get_url()

Then just implement a get_url() method or url property in your dialog class:

class UrlDialog(Gtk.Dialog):
    # Init etc...

    def get_url(self):
        return self.urlentry.get_text()
share|improve this answer
Thanks now it shows File "/home/aboobacker/mytube2/mytube2/", line 34, in on_newurlbutton_clicked url = dialog.get_url() File "/home/aboobacker/mytube2/mytube2/", line 61, in get_url return self.newurlentry.get_text() AttributeError: 'NewurlDialog' object has no attribute 'newurlentry' What does it mean ? – Tachyons Jul 2 '12 at 14:00
It worked ,thanks – Tachyons Jul 2 '12 at 14:38

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.