How to Automate IE without QTP/any Automation tool ?

Automate IE with VBS – We can use a plain and simple VBS file in order to perform basics tasks with IE efficiently and quickly without the use of any automation tool. Here’ s how we can open IE, navigate to a website and checkout its contents :-

<<Code>>

Set IE = CreateObject(“InternetExplorer.Application”)

IE.visible = 1

websiteName=”www.wordpress.com”

IE.navigate websiteName

Wscript.Sleep 5000

outertHTML = IE.document.documentelement.outerhtml

pageTitle=IE.Document.title

msgbox “HTML = ” & outerHTML

msgbox “Title = ” & pageTitle

Set IE=Nothing

<</Code>>

Happy Automating !

Harshit Kohli

Advertisements

Eat, Sleep, Automate. REPEAT !

Tagged with: , , , , , , ,
Posted in Awesum Stuff
2 comments on “How to Automate IE without QTP/any Automation tool ?
  1. Eeshan says:

    Dear Sir,

    Can we do the same for Firefox and Safari?

    With Regards,
    Eeshan

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Blog Stats
  • 168,130 hits
Categories

Enter your email address to follow this blog and receive notifications of new posts by email.

Join 796 other followers

%d bloggers like this: