pyqt drop to open a file

Discussion in 'Python' started by rui.li.spam@gmail.com, Mar 28, 2009.

  1. Guest

    Hi,

    anyone can give a simple example or a link on how to use 'drop' with
    pyqt.

    what I'm looking for is drop a file to main widget then program get
    the path\filename

    something like: main_widget set to accept 'drop event', set filename
    when 'drop event happens' then the filename is path\filename of the
    file user drag from any location to main widget.


    Thanks for any help.

    -Ray
    , Mar 28, 2009
    #1
    1. Advertising

  2. On Fri, 2009-03-27 at 17:55 -0700, wrote:
    > Hi,
    >
    > anyone can give a simple example or a link on how to use 'drop' with
    > pyqt.
    >
    > what I'm looking for is drop a file to main widget then program get
    > the path\filename
    >
    > something like: main_widget set to accept 'drop event', set filename
    > when 'drop event happens' then the filename is path\filename of the
    > file user drag from any location to main widget.


    Google is your friend:

    http://www.zetcode.com/tutorials/pyqt4/dragdrop/
    Albert Hopkins, Mar 28, 2009
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. SirPoonga
    Replies:
    2
    Views:
    742
    Ben Strackany
    Jan 7, 2005
  2. Oliver Klein
    Replies:
    0
    Views:
    675
    Oliver Klein
    Aug 24, 2003
  3. ulysses
    Replies:
    4
    Views:
    757
    Werner Schiendl
    Oct 22, 2003
  4. weiwei
    Replies:
    0
    Views:
    1,001
    weiwei
    Jan 5, 2007
  5. Mudcat
    Replies:
    2
    Views:
    967
    Mudcat
    Dec 14, 2008
Loading...

Share This Page