• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

How to login a particular website using VBA code ?

Kartheek

New Member
Hi... Here i am trying to opening a "Zerodha" website using my Credentials, can you please correct me where i am doing wrong. Thanks in advance for your answer.

>>> use code - tags <<<
Code:
Sub Test()
    Set ie = CreateObject("InternetExplorer.application")
    ie.Visible = True
    ie.Navigate ("https://kite.zerodha.com/" & ActiveCell)
    Do
        If ie.ReadyState = 4 Then
            ie.Visible = True
            Exit Do
        Else
            DoEvents
        End If
    Loop
    ie.Document.Forms(0).all("user id").Value = "TA1234"
    ie.Document.Forms(0).all("Password").Value = "xyz123"
    ie.Document.Forms(0).submit
   
End Sub

Sub internetlogon()
   With CreateObject("InternetExplorer.Application")
     .Navigate "https://kite.zerodha.com/"
     Do Until .ReadyState = 4
       DoEvents
     Loop
     DoEvents
     With .Document
        .items("username") = "TA1234"
        .items("usernamesend").submit
     End With
  End With
End Sub
 
Last edited by a moderator:
Back
Top