Results 1 to 4 of 4

Thread: [?] Input text programmatically

  1. #1

    Default [?] Input text programmatically

    How can i input text programmatically to QLineEdit to first application which use Qt 4.2 from second Win32Api application which don't use Qt ?
    SetWindowText and IAccessible:: put_accValue don't work...
    OS: Windows XP / Vista - 32 / 64

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,363
    Thanks
    3
    Thanked 5,012 Times in 4,791 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: [?] Input text programmatically

    You can send a message using PostMessage and then catch that message in the other application. You'll have to ask the message queue to give you access to win events though.

  3. #3

    Default Re: [?] Input text programmatically

    But if i can't modify source code of first application?

  4. #4
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,363
    Thanks
    3
    Thanked 5,012 Times in 4,791 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: [?] Input text programmatically

    I think you should be able to forge and post key events to the application and the default message handler should take care of the rest. But what should you put in that message is beyond the scope of this forum and you should consult WinAPI docs.

Similar Threads

  1. Unhandled exception in qatomic
    By NewGuy in forum Qt Programming
    Replies: 14
    Last Post: 23rd July 2013, 09:49
  2. Problem pasting text into a QTextEdit
    By Spockmeat in forum Qt Programming
    Replies: 8
    Last Post: 14th March 2009, 14:36
  3. Editable text in QGraphicsView
    By wysota in forum Qt Programming
    Replies: 8
    Last Post: 24th February 2007, 15:30
  4. visible text of textedit
    By regix in forum Qt Programming
    Replies: 3
    Last Post: 26th June 2006, 09:02

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.