Results 1 to 5 of 5

Thread: No such signal QLineEdit::textChanged(QString&)

  1. #1
    Join Date
    Jan 2007
    Posts
    95
    Thanks
    5
    Qt products
    Qt4
    Platforms
    Windows

    Default No such signal QLineEdit::textChanged(QString&)

    Someone knows what happend with this code:

    Qt Code:
    1. connect(TXTxinf2, SIGNAL(textChanged(QString&)), this, SLOT(TXTValidar_changed(QLineEdit *)));
    To copy to clipboard, switch view to plain text mode 

    Compile without warning or error, but when i run the program say this (linux Qt-4.3.1):

    Object::connect: No such signal QLineEdit::textChanged(QString&)

  2. #2
    Join Date
    Oct 2007
    Location
    Munich, Bavaria
    Posts
    144
    Thanks
    1
    Thanked 19 Times in 19 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Default Re: No such signal QLineEdit::textChanged(QString&)

    Because it's:
    void QLineEdit::textChanged ( const QString & text )

  3. #3
    Join Date
    Feb 2006
    Location
    Oslo, Norway
    Posts
    6,264
    Thanks
    36
    Thanked 1,519 Times in 1,389 Posts
    Qt products
    Qt4
    Platforms
    MacOS X Unix/X11 Windows Symbian S60 Maemo/MeeGo

    Default Re: No such signal QLineEdit::textChanged(QString&)

    Also, signal and slot parameters must match. It makes no sense to connect a signal with QString parameter to a slot with QLineEdit* parameter. You can use QSignalMapper or QObject::sender() to identify signal sender.
    J-P Nurmi

  4. #4
    Join Date
    Oct 2007
    Location
    Munich, Bavaria
    Posts
    144
    Thanks
    1
    Thanked 19 Times in 19 Posts
    Qt products
    Qt3 Qt4
    Platforms
    Unix/X11 Windows

    Lightbulb Re: No such signal QLineEdit::textChanged(QString&)

    @jpn:

    I WAS FASTER!
    But you have been more precise!

  5. #5
    Join Date
    Jan 2007
    Posts
    95
    Thanks
    5
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: No such signal QLineEdit::textChanged(QString&)

    I have just solve it. Thanks to all

Similar Threads

  1. can i connect a signal to a signal
    By amit_pansuria in forum Qt Programming
    Replies: 1
    Last Post: 29th August 2007, 06:28
  2. Replies: 3
    Last Post: 15th April 2007, 19:16
  3. Signal and slots
    By villy in forum Qt Programming
    Replies: 1
    Last Post: 12th January 2007, 10:10
  4. Replies: 2
    Last Post: 17th May 2006, 21:01
  5. no such signal QListBox::currentChanged()
    By jopie bakker in forum Newbie
    Replies: 2
    Last Post: 2nd March 2006, 15:17

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.