with out object repository i need to launch IE and then
navigate to a login page and then operate the objects
within the page. How will be the script?

Answers were Sorted based on User's Feedback



with out object repository i need to launch IE and then navigate to a login page and then operate ..

Answer / ramanestalu dasari

create instance object using InternetExplorer.Application

Ex: Dim IE
set IE=createobject("InternetExplorer.Application")
IE.navigate("www.gmail.com")
IE.visible=True
Browser().page().webedit().set "value"

Is This Answer Correct ?    3 Yes 0 No

with out object repository i need to launch IE and then navigate to a login page and then operate ..

Answer / sonal

Sample code to open browser and navigate to google site and
click on link.
------------------------------------------------------------
---------------------------------------------------------
If Browser("index:=0").Exist(1) then
wHandle1 = Browser("index:=0").GetROProperty
("hwnd")
hWindow = wHandle1
Browser("hwnd:=" & hWindow).Navigate
("http://www.google.com")
'msgBox "Opened URL"
Browser("hwnd:=" & hWindow).Sync
wait 2
Else
Call SystemUtil.Run
(BROWSER_EXE, "http://www.google.com", "", "open")
wHandle1 = Browser("index:=0").GetROProperty
("hwnd")
hWindow = wHandle1
Browser("hwnd:=" & hWindow).Sync
End If
Browser("hwnd:=" & hWindow).Page("title:=.*").Link
("name:=Images","index:=0").Click

Is This Answer Correct ?    1 Yes 0 No

with out object repository i need to launch IE and then navigate to a login page and then operate ..

Answer / rajesh

If Browser("index:=0").Exist(1) then
hWindow = getHandleBrowser
Browser("hwnd:=" &
hWindow).Navigate("http://www.google.com")
'msgBox "Opened URL"
Browser("hwnd:=" & hWindow).Sync
wait 2
else
SystemUtil.Run "iexplore.exe",
"http://www.google.com", "", "open"
hWindow = getHandleBrowser
Browser("hwnd:=" & hWindow).Sync
End If
Browser("hwnd:=" &
hWindow).Page("title:=.*").Link("name:=Images","index:=0").Click




Function getHandleBrowser
wHandle1 = Browser("index:=0").GetROProperty("hwnd")
getHandleBrowser = wHandle1
End Function

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More QTP Interview Questions

CAN I CALL A FUNCTION IN ACTION.IF YES PLEASE HELP ME

2 Answers   TCS,


What is exact meaning of Database Checkpoint in QTP 9.2 and what are the different types of the database check points?

0 Answers  


How to use checkpoints in qtp ?

0 Answers  


what sort of things what u put in Bug Report ?

1 Answers  


what is file database

1 Answers   Wipro,






What is expert view and keyword view?

0 Answers  


How to add multiple values in rows, under a single column of a run time datatable?

3 Answers   NIIT,


how to select the work for complete automation and one more thing when u are going to choose automation

3 Answers   Fidelity,


my assignment is,how can i differentiate between readed & unreaded mails in my inbox ?, since for both readed & unreaded having same properties for both test objects &run time objects

2 Answers  


How you perform smoke and sanity testing using qtp?

1 Answers   Tech Mahindra,


What is Automation frame work.How we will prepare in real time.

9 Answers   AppLabs,


what is check point?

2 Answers  


Categories