using ie.document.getElementById to submit form or click logon button in vb6

how do i click on a log on button  on a webpage using vb6 ie.document.getElementById(    statement.

the button for the webpage is below.
  <button type="submit" class="LogOnButton">Log On</button>

there is also the line
<form action="/Account/LogOn" method="post">

let me know if you need more infomation
rjefAsked:
Who is Participating?
 
NorieConnect With a Mentor VBA ExpertCommented:
If you want to submit the form try the code I posted.

That should be just the same as clicking the submit/logon button.
0
 
NorieVBA ExpertCommented:
Once you have the element you could just try it's click method.

Or if it's form you want to submit you could try something like this.

ie.document.forms(0).submit()

Open in new window


This would submit the first form on the page, if there is more than one form change 0 to get the right one.
0
 
rjefAuthor Commented:
how do i find the element?
0
Cloud Class® Course: Microsoft Office 2010

This course will introduce you to the interfaces and features of Microsoft Office 2010 Word, Excel, PowerPoint, Outlook, and Access. You will learn about the features that are shared between all products in the Office suite, as well as the new features that are product specific.

 
rjefAuthor Commented:
ok thanks
i will try when i get to work on friday
0
 
rjefAuthor Commented:
It worked but i had to remove the "()" on the submit

ie.document.forms(0).submit
0
 
rjefAuthor Commented:
any idea how to click on the check box from the below web site

<ol id="cabinetDocuments">
    
    <li class="line" rel="Scan_2014_02_04_12_55_04_036.pdf">        
        <div class="unit">
            <input type="checkbox" /><span class="doc-icon pdf" Title="Scan_2014_02_04_12_55_04_036.pdf">Scan_2014_02_04_12_55_04_036.pdf</span>
        </div>
        <div class="lastUnit">
            2/4/2014 1:22:04 PM
        </div>
    </li>
    
    <li class="line" rel="Scan_2014_02_04_12_53_55_486.pdf">        
        <div class="unit">
            <input type="checkbox" /><span class="doc-icon pdf" Title="Scan_2014_02_04_12_53_55_486.pdf">Scan_2014_02_04_12_53_55_486.pdf</span>
        </div>
        <div class="lastUnit">
            2/4/2014 1:20:58 PM
        </div>
    </li>

Open in new window

0
 
rjefAuthor Commented:
thanks
0
 
NorieVBA ExpertCommented:
That's kind of a whole different question.:)

Might even need the URL for the site to take a look at the rest of the source code.
0
 
rjefAuthor Commented:
i can send you the source.  i put another question in for it.  send me your email address to rjef041364@yahoo.com
0
 
rjefAuthor Commented:
the question is here
http://www.experts-exchange.com/Software/Internet_Email/Web_Browsers/Q_28359188.html

but you probably need more of the source.  Email me at rjef041364@yahoo.com  with your email and i will send it.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.