how to write vb script code for login gmail page by using
notepad and how to run script in notepad
Answer Posted / bittu
Write the below code in atext file and save it with .vbs
extension and run it. U will login into gmail automatically.
Provide the credentials in the line 10 & 11.
---------------------------------
WScript.Quit Main
Function Main
Set IE =
WScript.CreateObject("InternetExplorer.Application", "IE_")
IE.Visible = True
IE.Navigate "http://www.gmail.com"
Wait IE
With IE.Document
.getElementByID("Email").value = "abcd"
.getElementByID("Passwd").value = "xyzp"
.getElementByID("gaia_loginform").submit
End With
End Function
Sub Wait(IE)
Do
WScript.Sleep 500
Loop While IE.ReadyState < 4 And IE.Busy
Do
WScript.Sleep 500
Loop While IE.ReadyState < 4 And IE.Busy
End Sub
Sub IE_OnQuit
On Error Resume Next
WScript.StdErr.WriteLine "IE closed before script finished."
WScript.Quit
End Sub
Is This Answer Correct ? | 0 Yes | 10 No |
Post New Answer View All Answers
Program to use input box and send even numbers into sheet1 and odd numbers into sheet2 and prime numbers into sheet3 using vbscript(QTP)?
write any ttest cases using check points and parameterization
Explain the constants in vbscript?
Explain the extension .hta?
I need to get some data from data base and store this
(retrieved) data in a excel sheet using VB script in QTP9.0
I have created connection for data base
I have created as excels sheet by using
Set XL=CreateObject("Excel.Application")
XLworksheet.cells(1,1).value= rs.fields.item("<
How can you create an object in vbscript?
What are keywords in the vbscript language?
How will you get the exponent of the given number in vbscript?
How to capture a runtime error in vbscript?
Explain about arrays in vb script?
Can any one provide code for Mid(string,start[,length]). I have been asked to write code for Mid(). i.e We need to define our own function say MyMid() which should behave same like built-in Mid function
what is the features of visual basic?
How will you convert a given number to long in vbscript?
who will create the object?
Explain the tristate constants in vbscript?