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.


    Extraction and tags finders

    avatar
    kapowman11


    Posts : 4
    Points : 1801
    Join date : 2019-05-30

    Extraction and tags finders Empty Extraction and tags finders

    Post by kapowman11 Tue Oct 22, 2019 6:19 pm

    Hi,

    Totally new to RPA, which we are looking at implementing in our company 
    Find attached a .html page in zipped format, which can be used for testing. The Html file will be placed on my desktop.

    I have been following examples and tutorials and am starting to get the hang of Design Studio.
    I can't quite figure out the following:

    In a table I have a lot of customers 
    It is an extraxct from an ERP-system, so can't be changed.
    Two classes exist in <tr> : "odd" and "even"

    1) I click the link on the webpage (It will take me to a specific customerpage)

    2) When I click I would like to Extract the URL of the link - stuff it in a variable
    2.1) The value(number) of the customer (in this first <tr> it is 0) /stuff it in a variable
    2.2 The value "Customer Pedersen" and stuff it in a variable

    I am struggling to make it dynamic, meaning the same thing should happen regardless of which customer's link I press, I can get the values but only the one I clicked in the GUI
    In the attached .html file I have placed three customers.  

    File attachment size was 0 ??? Below is the relevant .htrml file


    <html>
    <head>
    <title>CustomerList</title>

    </head>
    <body>
    <h2>Our Customer List</h2>
    <table id="myTable" class="tablesorter tablesorter-default" style="">
    <tr class="odd">
    <td><a href="file:/W:/Deployment/customer/kundeliste/cus0.html">0</a></td>

    <td><a href="file:/W:/Deployment/customer/kundeliste/cus0.html">Customer Pedersen</a></td>

    <td></td>
    </tr>

    <tr class="even">
    <td><a href="file:/W:/Deployment/customer/kundeliste/cus1.html">1</a></td>

    <td><a href="file:/W:/Deployment/customer/kundeliste/cus1.html">Customer Hansen</a></a></td>

    <td></td>
    </tr>


    <tr class="odd">
    <td><a href="file:/W:/Deployment/customer/kundeliste/cus4.html">4</a></td>

    <td><a href="file:/W:/Deployment/customer/kundeliste/cus4.html">customer Johnsson</a></td>

    <td></td>
    </tr>


    </table>
    </body>
    </html>


    Any help would be appreciated. Thank you for your time

    Best Regards.
    avatar
    kapowman11


    Posts : 4
    Points : 1801
    Join date : 2019-05-30

    Extraction and tags finders Empty Re: Extraction and tags finders

    Post by kapowman11 Tue Oct 22, 2019 8:57 pm

    Found solution myself.
    Seems that the "for each URL" step is not as easy to get working as the "for each tag path"

    Use the for each tag path and at the Action tag put "odd|even" in the "Classes to include"
    Mark the entire <tr class="odd/even"></tr> section where you have the values. 
    Then use the "extract Text" step for whatever text you wish to extract.

    Solved.

      Current date/time is Sun Apr 28, 2024 1:38 am