Results 1 to 3 of 3

Thread: API Tab Key

  1. #1

    Thread Starter
    Member
    Join Date
    Aug 2000
    Posts
    59

    Cool

    When sending the Tab command to an application can you use this?
    Code:
    Private Sub Command1_Click()
    dim StrTab as Long
    StrTab=SendMessage(hWnd,WM_CHAR,vbKeyTab,0)?
    End Sub

    I try that code alread to send the tab key to an application but it does not work does anybody know of another way? by the way the application is a Web Page with 2 text boxes. I want to be able to send a message to the first box and then to the second box but the vbKeyTab is not helping.


    Thanx




  2. #2
    Fanatic Member gwdash's Avatar
    Join Date
    Aug 2000
    Location
    Minnesota
    Posts
    666
    try this
    Code:
    Dim retval
    retval = SetForeGroundWindow(hWnd)
    SendKeys("{Tab}")
    Not Tested, will make your other window default, then send tab key
    GWDASH
    [b]VB6, Perl, ASP, HTML, JavaScript, VBScript, SQL, C, C++, Linux , Java, PHP, MySQL, XML[b]

  3. #3

    Thread Starter
    Member
    Join Date
    Aug 2000
    Posts
    59

    Cool

    It did not work. Is a web-page and the web-page has 2 "Edit controls" or (text boxes). First i want to send a message to the first box then i want my application to send the Tab key to set the cursor in the next box. I want the focus to be on the other box.

    thanx

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