Explain the keyword createobject with an example.



Explain the keyword createobject with an example...

Answer / sreeprasad

Creates and returns a reference to an Automation object

syntax: CreateObject(servername.typename [, location])

Arguments

servername:Required. The name of the application providing

the object.

typename : Required. The type or class of the object to

create.

location : Optional. The name of the network server where

the object is to be created.

Is This Answer Correct ?    2 Yes 0 No

Post New Answer

More QTP Interview Questions

can we install qtp in windows vista

2 Answers  


How to load a object repository(using VBScript) ... very urgent....

4 Answers  


How to capture screen shots when an error occurs?

2 Answers  


VM1 = "Invalid username or password. Please try again. " VM2 = "Email id is required.Password is required. " VM3 = "Email id is an invalid e-mail address.Password is required. " VM4 = "Password is required. " VM5 = "Email id is required. " VM6 = "Email id is an invalid e-mail address. " 'Rowcount of the Local sheet Rowcount = DataTable.GetSheet("Invalid login transactions").GetRowCount 'Valid emailid and Password Emailid = "test@iteamic.com" Password = "Password0" 'For i = 1 to Rowcount 'Parameterised Email_id Browser("Browser").Page ("Page").WebEdit("emailAddress").Set DataTable("Email_id", dtLocalSheet) EID = Browser("Browser").Page ("Page").WebEdit("emailAddress").GetRoProperty("value") 'Parameterised Password Browser("Browser").Page ("Page").WebEdit("password").Set DataTable("Password", dtLocalSheet) PWD = Browser("Browser").Page ("Page").WebEdit("password").GetROProperty("Value") If EID = Emailid And PWD = Password Then Reporter.ReportEvent micPass, "EID & PWD check", "Email id and Password is correct, One iteration of Invalid login attempts is not being executed" Else Browser("Browser").Page("Page").WebButton ("Sign-In").Click 'Output value exported to the local sheet Browser("Browser").Page ("Page_2").Output CheckPoint("Home page_Sign in") 'Storing the output value in a variable(OUTPUT OUTPUT = Datatable.GetSheet ("Invalid login transactions").Getparameter ("Validation_message_signin").value 'comparing the Variable Output and the Validation message for a given input If OUTPUT = VM1 Then Reporter.ReportEvent micPass, "VM1", "Invalid username or password. Please try again. " else if OUTPUT = VM2 Then Reporter.ReportEvent micPass, "VM2", "Email id is required.Password is required. " else if OUTPUT = VM3 Then Reporter.ReportEvent micPass, "VM3", "Email id is an invalid e-mail address.Password is required. " else if OUTPUT = VM4 Then Reporter.ReportEvent micPass, "VM4", "Password is required. " else if OUTPUT = VM5 Then Reporter.ReportEvent micPass, "VM5", "Email id is required. " else if OUTPUT = VM6 Then Reporter.ReportEvent micPass, "VM6", "Email id is an invalid e-mail address. " else Reporter.ReportEvent micFail, "EID & PWD check_FAIL", "Validation message checkpoint failed. The captured v msg is not required" End if End if I am getting syntax error saying "Expected 'End If'" at the last line, Why is this? Kindly explain...

1 Answers  


how qtp will recognise if application is run on many browsers

1 Answers   Cap Gemini,






What is the difference between Dim And Redim

4 Answers   Hotel Jobs, IBM, Microsoft,


I have some real time based question.. 1.what are the challenges you have faced in your current project. 2.what are the bugs you found in your current project. 3.what are the strategies you follow to convert manual test cases into automation test cases. 4.how QTP identify two different browsers. 5. When you create a function library and share object repository what are the problems you have faced 6. How to solve the tool tip problem 7.what are the interesting bug you have found in your current project. 8.what is your daily work as a automation test engg. 9. how to create a weekly status report. 10. how many test cases you write,review and execute per day. 11.what are the uses of SQL in automation. 12.How to retrieve the data in html through vb script. 13.If application is very slow how to test the application in qtp.

0 Answers   Cap Gemini, TCS,


Explain about merging of two repositories?

3 Answers  


In QTP, Give the difference of Global sheet and Local sheet in datatable?

3 Answers  


why was automation used in the project?

1 Answers   Google,


How to recognize and read data from pdf file using Descriptive Programming in QTP?

1 Answers   Satyam,


can anyone tell me how to search a word/line in a document and to paste it in another file? Thanks in advance.

4 Answers  


Categories