GeekInterview.com
Results 1 to 2 of 2

General run error running childobject

This is a discussion on General run error running childobject within the QTP forums, part of the Software Testing category; I am getting a general run error on the "Set Links" portion of this function... Can somebody please help? Thanks. Function fnMatchLink(ExpectedStr, LinkTag, LinkClass) Dim oMatchLink, LinkItem, w, LinkFound, ButtonClick, ...

  1. #1
    DeaconBlack is offline Junior Member Array
    Join Date
    Sep 2012
    Answers
    1

    General run error running childobject

    I am getting a general run error on the "Set Links" portion of this function... Can somebody please help? Thanks.



    Function fnMatchLink(ExpectedStr, LinkTag, LinkClass)

    Dim oMatchLink, LinkItem, w, LinkFound, ButtonClick, Links

    Set oMatchLink = Description.Create()
    oMatchLink("micclass").Value = "Link"
    oMatchLink("html tag").Value = LinkTag
    oMatchLink("class").Value = LinkClass
    Set Links = varPageTreeFrame.ChildObjects(oMatchLink)


  2. #2
    jacosta is offline Junior Member Array
    Join Date
    Mar 2013
    Answers
    4

    Re: General run error running childobject

    Hi, try this:

    Function fnMatchLink(ExpectedStr, LinkTag, LinkClass)

    Dim oMatchLink, LinkItem, w, LinkFound, ButtonClick, Links

    Set oMatchLink = Description.Create()
    oMatchLink("micClass").Value = "Link"
    oMatchLink("html tag").Value = LinkTag
    Set Links = varPageTreeFrame.ChildObjects(oMatchLink)

    'oMatchLink("class").Value = LinkClass == oMatchLink("micClass").Value = "Link"

    bye...