Results 1 to 4 of 4

Thread: [RESOLVED] Trying to send message to a textbox on Internet Explorer

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Apr 2002
    Posts
    121

    Resolved [RESOLVED] Trying to send message to a textbox on Internet Explorer

    I'm using myspace on the Internet, and I want to send a personal message to all of my buddies. I want the message to say something like "Ski trip on Wed," but in order to do it, I need to send the message to the textbox in the webpage presumably by using API and sendmessage. When I use Spy++ it won't lock onto the textbox on the webpage. Is this possible to do?

    I thought that, if necessary, I could get the coordinates of where the textbox is and somehow send a message to it. I know I can use the coordinates to click it, but am not sure about sending a message to it.

    Can anyone help, or is this just not possible?

    Thanks,
    Brad

  2. #2
    INXSIVE Bruce Fox's Avatar
    Join Date
    Sep 2001
    Location
    Melbourne, Australia
    Posts
    7,429

    Re: Trying to send message to a textbox on Internet Explorer

    If it's a Web Page, you dont need to use SPY++/API etc.

    I don't have any code handy where I am at the moment. However a search will reveal tons of examples relating to filling in web pages etc.

  3. #3

    Thread Starter
    Lively Member
    Join Date
    Apr 2002
    Posts
    121

    Re: Trying to send message to a textbox on Internet Explorer

    Thanks. I searched for code related to filling in a textbox on a web page, but I don't understand the code. This is the easiest example I could find, but I'm completely lost. It's for filling in a textbox on a web page (http://www.vbforums.com/showthread.php?t=282948&):

    VB Code:
    1. With WB.Document
    2.         If WB.ReadyState = READYSTATE_COMPLETE Then
    3.             .getElementById("email").Value = "myemail.email.com"
    4.             .getElementById("comments").Value = "test"
    5.             .Forms(0).Submit
    6.         End If
    7.     End With

    I'm not sure what WB.Document, .getElementById, etc. mean or why they are used. Is there a place that would help me understand them? When I try to run this code during a click event in VB it highlights the 'WB' and says 'variable not defined.' Also '.Document' comes after 'WB.' why would I have 'Document' in my code if I'm working with a web page?

    Thank you,
    Brad

  4. #4

    Thread Starter
    Lively Member
    Join Date
    Apr 2002
    Posts
    121

    Re: Trying to send message to a textbox on Internet Explorer

    I found out what was wrong. I needed to add the component.

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