KAPOW

Would you like to react to this message? Create an account in a few clicks or log in to continue.
KAPOW

Welcome to the Kapow forum. Here you can get help, use your skills to help others and enjoy hanging out in the company of other Kapow Robot Developers.


2 posters

    Device Automation - Finding a specific text

    avatar
    Jacob.Helenius


    Posts : 2
    Points : 1775
    Join date : 2020-01-10

    Device Automation - Finding a specific text Empty Device Automation - Finding a specific text

    Post by Jacob.Helenius Thu Jan 23, 2020 7:18 pm

    Hi,

    I am building a robot using Kapow version 10.3.0.6.

    The robot needs to log in to a system using Device Automation, where I wan't to extract a specific value.
    Normally in other systems I am able to extract a value by right clicking on the field I wan't to extract, or by finding the location in the code below.
    In this system, the order of the values and the ID's (TD values in the code) varies.

    I was hoping I could use a "For Each Loop" (over the whole of the area I am searching for the specific value) and a "Element Selector" where I search for the specific value, but I can't make it work.

    Have anyone had the same problem, and did you find a solution? Smile

    Kind regards,
    Jacob
    avatar
    tmc51


    Posts : 6
    Points : 1757
    Join date : 2020-02-04

    Device Automation - Finding a specific text Empty Re: Device Automation - Finding a specific text

    Post by tmc51 Tue Mar 10, 2020 4:10 am

    Hi Jacob,

    Is the text you are looking for static? if so -
    You can achieve this by looping and assigning the attribute value to a variable each loop, then you would run a conditional step to check if the this variable. I have achieved this by using the contains method, example below. From here you would do something like place the following steps inside the conditional step.

    Device Automation - Finding a specific text Test_d10


    Hopefully this helps.

    Regards.
    avatar
    Jacob.Helenius


    Posts : 2
    Points : 1775
    Join date : 2020-01-10

    Device Automation - Finding a specific text Empty Re: Device Automation - Finding a specific text

    Post by Jacob.Helenius Tue Mar 10, 2020 2:32 pm

    Hi,

    Thanks for the reply Smile
    Sadly the text I am looking for isn't static, but after a lot of trial and errors, I managed to get the right result:

    Component formel:
    pane[automationId="pnlSearch"]>pane:nth-of-type(3)>edit[automationId="dateMaskedTextBox"]
     
    Where the selector is looking for the 3rd of a specific type, in a specific place in the tree.

    Regards,
    Jacob

    Sponsored content


    Device Automation - Finding a specific text Empty Re: Device Automation - Finding a specific text

    Post by Sponsored content


      Current date/time is Fri Nov 15, 2024 12:00 pm