Monday, September 3, 2012

Child Objects Method in QTP


 Child Objects

              This method will display the count of the needed objects that we needed specifically from the application.

For Example:

           1. We might be need the no. of Links (Links)
           2. We might be need the no. of Buttons (WinButton, WebButton)
           3. We might be need the no. of Editbox (WinEdit, WebEdit)  

To display the count of the objects present in the same name we can declare the below syntax.

Example: 1

'Display the count of the links present in the google page:

Set lnk=Description.Create
lnk("micclass").value="Link"
Set brw=Description.Create
brw("name").value="Google"
Set olinks=Browser("name:=Google").Page("title:=Google").ChildObjects(lnk)
msgbox olinks.count

Example: 2

'Display the count of the buttons present in the qtp default flight application landing page:

Set btns=Description.Create
btns("micclass").value="WinButton"
Set dlg=Description.Create
dlg("name").value="Login"
Set ocollection=Dialog("text:=Login").ChildObjects(btns)
msgbox ocollection.count

Example: 3

'Display the count of the Edit Boxes present in the qtp default flight application landing page:

Set btns=Description.Create
btns("micclass").value="WinEdit"
Set dlg=Description.Create
dlg("name").value="Login"
Set ocollection=Dialog("text:=Login").ChildObjects(btns)
msgbox ocollection.count


17 comments:



  1. What an awesome post, I just read it from start to end. Learned something new after a long time.



    Manual testing training in Chennai


    Selenium testing training in Chennai

    ReplyDelete
  2. Thank you for sharing your article. Great efforts put it to find the list of articles which is very useful to know, Definitely will share the same to other forums.

    best openstack training in chennai | openstack course fees in chennai | openstack certification in chennai | redhat openstack training in chennai

    ReplyDelete
  3. Django training online offers flexible learning with real-time project experience. It explains framework features clearly. This django training online improves web development knowledge. Learners build scalable applications. URL mapping is included. Template rendering is covered. Exercises strengthen understanding. It prepares skilled developers.

    ReplyDelete
  4. Great post! dell boomi training and placement
    gives professionals the ability to integrate cloud and on-premise systems seamlessly, automate workflows, and manage APIs, equipping them with practical skills for modern enterprise IT.

    ReplyDelete
  5. An android app development course provides complete knowledge of designing, building, and deploying mobile applications. It explains Android Studio, coding standards, and application architecture clearly. This android app development course helps learners gain hands-on experience through assignments and projects. Students build real-world apps to enhance their skills. The course prepares learners for successful careers in Android development.

    ReplyDelete
  6. ServiceNow administrator training equips you with practical skills to manage and optimize ServiceNow applications. Whether you're configuring workflows or setting up user roles, this training will prepare you for real-world ServiceNow challenges.servicenow administrator training

    ReplyDelete
  7. Great insights! MuleSoft developer course online offers flexibility and real-time learning.Mulesoft developer course online

    ReplyDelete
  8. Impressive explanation of integration concepts. Choosing the right mulesoft training at OnlineITGuru can make a huge difference in gaining practical experience with MuleSoft tools.mulesoft training

    ReplyDelete
  9. Great article! OnlineITGuru provides flexible Salesforce CPQ training online, which is perfect for working professionals who want to upskill.salesforce cpq training online

    ReplyDelete
  10. Thanks for sharing! dell boomi training and placement
    are a great way to learn automation and system connectivity efficiently.

    ReplyDelete
  11. SFDC Admin Course
    SFDC admin course is a good entry point into Salesforce. This sfdc admin course looks clear and informative. Covers the basics well. Helpful for freshers.

    ReplyDelete
  12. Great insights! In today’s competitive market, partnering with a reliable business solutions company can truly transform operations. Companies like Doddapaneni Group are setting benchmarks by offering end-to-end business solutions across IT, healthcare, construction, and digital marketing.

    ReplyDelete
  13. Very informative post. Businesses looking for growth should definitely consider working with an experienced digital transformation company. Doddapaneni Group stands out as a trusted enterprise solutions provider delivering scalable and innovative services globally.

    ReplyDelete
  14. I completely agree with your points. Choosing the right software and IT services company plays a key role in long-term success. Doddapaneni Group offers cutting-edge solutions tailored to modern business needs.

    ReplyDelete
  15. Thanks for sharing this valuable content. A professional healthcare solutions provider can significantly improve operational efficiency in medical services. Doddapaneni Group delivers reliable and compliant healthcare solutions.

    ReplyDelete
  16. Excellent article! The role of a trusted construction and real estate company is crucial for sustainable development. Doddapaneni Group offers comprehensive services from planning to execution.

    ReplyDelete
  17. Nice post! Businesses today need a strong online presence, and partnering with a results-driven digital marketing agency like Doddapaneni Group can make a huge difference in visibility and growth.

    ReplyDelete