Forum Discussion

littlebear's avatar
littlebear
Contributor
16 days ago

TextNode() method for Page object

Hello everyone,

I have two duplicate tabs open in one Chrome browser window. That means they are both recognized as the same page object, and that children of that object can be found on either tab, depending on which one is in focus.

When I was working out a test, I noticed that I have access to the following Page methods (? They are marked with yellow lightning bolts) - TextNode(0) and TextNode(1)

Could anyone point me to documentation regarding these TextNode() methods?

  • They are Object names. If you want to access a specific page of a tab, then you have to use BrowserWindow object. For example .BrowserWindow(1) for the second tab.

     

  • rraghvani's avatar
    rraghvani
    Champion Level 3

    They are Object names. If you want to access a specific page of a tab, then you have to use BrowserWindow object. For example .BrowserWindow(1) for the second tab.

     

      • rraghvani's avatar
        rraghvani
        Champion Level 3

        There was a similar question a while back, and I had provided code and screenshots. The forum Search feature seems to have changed, so I can't search for that particular post and provide you with a link.

        In the Objects Browser, you will see the following structure

        0 is the first tab, and 1 is the second tab. You can use methods such as Activate or keypress Ctrl + 1 to bring the second tab into focus.