Results 1 to 4 of 4

Thread: Have Trouble submit to this form

  1. #1

    Thread Starter
    Fanatic Member newprogram's Avatar
    Join Date
    Apr 2006
    Location
    in your basement
    Posts
    769

    Have Trouble submit to this form

    All I need is to send a click to this button here my code
    WebBrowser1.Document.getElementById("button").Click

    here the html of the form

    <form method="post" action="https://post.jsuhdf.org/manage/156238079/mg9hf?button=publish">
    <input type="hidden" name="button" value="publish">
    <b>This posting is <font color="red">unpublished:</font></b> <input type="submit" value="publish posting 156238079"></form>
    Last edited by newprogram; May 1st, 2006 at 03:46 PM. Reason: [sloved]

  2. #2

    Thread Starter
    Fanatic Member newprogram's Avatar
    Join Date
    Apr 2006
    Location
    in your basement
    Posts
    769

    Re: Have Trouble submit to this form

    Quote Originally Posted by newprogram
    All I need is to send a click to this button here my code
    WebBrowser1.Document.getElementById("button").Click

    here the html of the form

    <form method="post" action="https://post.jsuhdf.org/manage/156238079/mg9hf?button=publish">
    <input type="hidden" name="button" value="publish">
    <b>This posting is <font color="red">unpublished:</font></b> <input type="submit" value="publish posting 156238079"></form>
    anyone

  3. #3
    Junior Member
    Join Date
    May 2005
    Posts
    18

    Re: Have Trouble submit to this form

    VB Code:
    1. 'Use sendkeys to simulate the enter key being pressed
    2. 'while focus is on submit button
    3.  
    4. Dim hDoc As MSHTML.HTMLDocument
    5. Dim hInp As MSHTML.HTMLInputElement
    6.  
    7. Set hDoc = WebBrowser1.document
    8. Set hInp = hDoc.getElementById("button")
    9. hInp.focus
    10. SendKeys "{ENTER}", True

  4. #4
    Member
    Join Date
    Sep 2004
    Posts
    52

    Re: Have Trouble submit to this form

    WebBrowser1.document.body.childNodes.item(2).click ??

    or

    WebBrowser1.document.body.childNodes.item(2).submit ??

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