Results 1 to 6 of 6

Thread: Find any textbox & place text in it

  1. #1

    Thread Starter
    Hyperactive Member MikeBAM's Avatar
    Join Date
    Sep 2000
    Location
    Metro Detroit
    Posts
    284

    Find any textbox & place text in it

    I would like to make a feature on my program that you can drag a pointer into a Textbox or Combo Box or and object that you can place actual text in.
    Most of the time it would be a chat room text box and some kind of instant message textbox. But the idea is that it should work on any application hopefully.

    I'm thinking maybe first send text to the object then Get the text from the object to see if it comes back? Maybe that would be an easy way to see if it's a text box like object.. WAIT.. no.. I guess that wouldn't work because you can send text to any window and get it back. :/

    Basically it should be like an API Spy but the user wouldn't know anything about that.
    This should find the object and then probably save it in a variable. But that's not hard to save it.
    I just don't know how to get the handle of any window/object a normal user MouseUps on, and be able to tell if it's a textbox.

    Any help?
    ~* )v( ! /< E *~

  2. #2
    Conquistador
    Join Date
    Dec 1999
    Location
    Australia
    Posts
    4,527
    Have a look on planet source code for a program called
    API Spyer I think

    That should be a good start as it allows you to drag a pointer onto a handle, then you could easily put text in it...

  3. #3

    Thread Starter
    Hyperactive Member MikeBAM's Avatar
    Join Date
    Sep 2000
    Location
    Metro Detroit
    Posts
    284
    I tryed i'm not getting very far.

    Is there a command from hitting CTRL on an object like you can with enter?

    Call SendMessageLong(TheWindow, WM_CHAR, 13, 0&)

    if 13 is enter what is CTRL ?
    ~* )v( ! /< E *~

  4. #4
    Conquistador
    Join Date
    Dec 1999
    Location
    Australia
    Posts
    4,527
    are you wanting to past text into a textbox

    What application is the textbox in?

  5. #5

    Thread Starter
    Hyperactive Member MikeBAM's Avatar
    Join Date
    Sep 2000
    Location
    Metro Detroit
    Posts
    284
    Yeah i'm trying to post text in a text box, and/or SendMessageByString SendMessage what ever!
    I can do that No Problem.
    The thing is that i want this to be able to work for any applacation! The user would drag and drop a pointer over the apps. textbox and my program would get the name and path of it and then send text to it, post text to it, sendmessage to it.. whatever it may be.
    GET IT?
    ~* )v( ! /< E *~

  6. #6
    Conquistador
    Join Date
    Dec 1999
    Location
    Australia
    Posts
    4,527
    GetCursorPos and WindowFromPoint would work in this instance.

    Have a look on www.vbapi.com

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width