Robotic Process Automation (RPA)

 View Only
  • 1.  The official tutorial cannot be executed

    IBM Champion
    Posted Mon September 27, 2021 11:49 PM
    I follow the tutorial in the following official link to learn RPA and can't execute it. Who has an RPA script that can be executed? Please send me a few to learn.
    https://www.ibm.com/docs/en/rpa/21.0?topic=tutorials-getting-values-from-web-page


    defVar --name pathMyDocuments --type String
    defVar --name directoryObtainedFiles --type String
    defVar --name instanceName --type String --value "browser-instance"
    defVar --name ratesForCountries --type DataTable
    defVar --name tableRow --type Numeric --value 1
    defVar --name countriesColumn --type String
    defVar --name rateColumn --type String
    defVar --name pathCsvFile --type String
    defVar --name fileExists --type Boolean
    defVar --name countriesColumnName --type String
    defVar --name rateColumnName --type String
    defVar --name companyData --type String
    defVar --name graphCompany --type Image
    getSpecialFolder --folder "MyDocuments" pathMyDocuments=value
    createDir --path "${pathMyDocuments}\\rpa_challenge_tutorial" directoryObtainedFiles=value
    webStart --name "${instanceName}" --type "Firefox"
    webNavigate --url "http://rpachallenge.com/assets/rpaStockMarket/index.html"
    webWait --timeout "00:00:30"
    webGetTable --selector "CssSelector" --css "body>div>div.cinsert>div>div.items>table" --timeout "00:00:30" ratesForCountries=value
    logMessage --message "${ratesForCountries}" --type "Info"
    for --variable ${tableRow} --from 1 --to ${ratesForCountries.Rows} --step 1
        mapTableRow --dataTable ${ratesForCountries} --row ${tableRow} --mappings "number=1=${countriesColumn},number=2=${rateColumn}"
        setVar --name "${pathCsvFile}" --value "${directoryObtainedFiles}\\rates-per-country.csv"
        ifFile --file "${pathCsvFile}" fileExists=value
        if --left "${fileExists}" --operator "Is_True" --negate
            getColumnName --dataTable ${ratesForCountries} --index 1 countriesColumnName=value
            getColumnName --dataTable ${ratesForCountries} --index 2 rateColumnName=value
            writeToFile --value "${countriesColumnName},${rateColumnName}" --file "${pathCsvFile}" --encoding "Default"
        endIf
    next
    writeToFile --value "$countriesColumn},${rateColumn}" --file "${directoryObtainedFiles}\\rates-per-country.csv" --encoding "Default" --writeasnewline
    webSetComboBox --selectoptionby "Value" --value "WEX Academy Inc.</ li>" --selector "Id" --id country --timeout "00:01:00"
    webGet --selector "CssSelector" --css "body > div > div.cinsert > div > div.innercontainer > div.inneritem1" --timeout "00:01:00" companyData=value
    writeToFile --value "${companyData}" --file "${directoryObtainedFiles}\\text-data-company.txt" --encoding "Default" --overwrite
    webGetImage --selector "CssSelector" --css "body > div > div.cinsert > div > div.innercontainer > div.inneritem2 > img" --timeout "00:01:00" graphCompany=value
    saveImage --image ${graphCompany} --directory "${directoryObtainedFiles}" --file "company-graph" --format "Jpeg"
    webClose --name "${instanceName}"

    ------------------------------
    ding wei
    ------------------------------


  • 2.  RE: The official tutorial cannot be executed

    Posted Tue September 28, 2021 04:56 AM
    Edited by NIGEL CROWTHER Tue September 28, 2021 04:58 AM
    Hi Wei,

    There are plenty of labs you can use to learn RPA in the RPA library.  If you go into the RPA tutorials folder you will find them:

    RPA Library



    ------------------------------
    NIGEL CROWTHER
    ------------------------------



  • 3.  RE: The official tutorial cannot be executed

    IBM TechXchange Speaker
    Posted Tue October 05, 2021 10:08 AM
    Hi Ding Wei,
    I've also alerted the document team that you having an issue with this and they are putting it in their list to correct it. 

    Thanks!

    ------------------------------
    Stephanie Wilkerson
    IBM
    ------------------------------