Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


Can Any One Write How to Write the Script for Child Objects

Answers were Sorted based on User's Feedback



Can Any One Write How to Write the Script for Child Objects..

Answer / deven

Dim obj_ChkDesc

Set obj_ChkDesc=Description.Create

obj_ChkDesc(“html tag”).value = “INPUT”

obj_ChkDesc(“type”).value = “checkbox”

Dim allCheckboxes, singleCheckBox

Set allCheckboxes = Browse(“Browser”).Page
(“Page”).ChildObjects(obj_ChkDesc)

For each singleCheckBox in allCheckboxes
singleCheckBox.Set “ON” Next

Note: It will check all the check boxes on the page with
Child object

Is This Answer Correct ?    0 Yes 0 No

Can Any One Write How to Write the Script for Child Objects..

Answer / sandeepguttikonda

Child Objects are used to perform the operations on similar
data.

Example: to get the total number of link in a Page:

And we can perform this by using the below code:

/* Creating the description object*/
Set oDescFrame = Description.Create
oDescFrame("micclass").Value = "links"

Set Links_Count = Browser("name:="&Browsername).page
("title:="&Pagetitle).ChildObjects(oDescFrame)

Msgbox &Links_count.count

This will display the total number of links in a page.

Please let me know if you need any further info.

Thanks.

Regards,
Sandeep Guttikonda

Is This Answer Correct ?    0 Yes 1 No

Can Any One Write How to Write the Script for Child Objects..

Answer / manohar

Sorry , Actuvally i want the Example script for Using the
Child objects.
Iam not sure of using the Child Objects . I know the script
that which you had written for Fikle system Objects.

Is This Answer Correct ?    0 Yes 2 No

Can Any One Write How to Write the Script for Child Objects..

Answer / kanda

Here i am giving one example to create New file in New
Folder and to write a "Hello World" in that file

File System Object Model
----------------------------
set fso =createobject("scripting.filesystemobject")
set newfolder = fso.createfolder("C:\QTP",True)
Set newfile = newfolder.createtextfile("C:\QTP\Test1",True)
newfile.writeline("Hello World")
newfile.close


Try with tis..I hope it will work

Is This Answer Correct ?    1 Yes 4 No

Post New Answer

More QTP Interview Questions

What is checkpoint in qtp?

0 Answers  


i need to learn the descriptive programming very well so for that what to do am reading the qtp user mannual but it is not so any materials or links with examples i want please help me

2 Answers  


Write a function which returns the addition of two numbers. give the value of the numbers outside the function.

3 Answers   SAP Labs,


What are the recording modes and executing modes avialble in QTP?

3 Answers   Polaris,


Hi, one script having 10 Actions,but i want to execute only 3rd action and 7th action? how to execute selected actions? throgh script and through navigation?

2 Answers   IBM,


What is an expert view and keyword view?

0 Answers  


I have a drop down box to show selected number of records in result page.It contains 4 items like 10, 25,50 and 100. when i was recordes script for seelcting each item and checking selecting number of records in the result page( it is in the same page in the table format)it is generating a new page with same controls( objects) in the OR. how to avaid these in OR? is it possible to write DP for only these lines?, remaining(remaingin lines of code) objects i want use from OR only. One more problemis if change ( add /remove properties of an OBJECT in OR , my ( recorded )application is not running.

5 Answers   Virtusa,


How to find local host name using QTP?

6 Answers  


Where you get the run time data table?

0 Answers  


i need the licence key for QTP V9.5 can anyone help me on getting this?

140 Answers  


I want to do Certification course in QTP. For this I request you to suggest the best Tutorial in PDF format. Hence, if possible, kinldy mail PDF file to my mail-ID: sushmapokhriyal79@gmail.com

0 Answers  


How are actions and functions different in QTP?

0 Answers  


Categories