Purpose
From UBot Studio
(Difference between revisions)
(Created page with "This command is a Flow Command. This command writes a message to a log file that provides an overview of what a bot is trying to accomplish. '''Purpose:''' ...") |
|||
Line 44: | Line 44: | ||
− | [[File: | + | [[File:blpurpose.jpg]] |
Revision as of 21:55, 15 March 2015
This command is a Flow Command. This command writes a message to a log file that provides an overview of what a bot is trying to accomplish.
Purpose: The message that will be logged as the purpose of the script.
Example
navigate("https://www.google.com","Wait") click(<title="Go to Google Home">,"Left Click","No") purpose("Check to Make Sure Webpage is Google.com") activity("Beginning Webpage Check...") set(#page were on,$scrape attribute(<id="hplogo">,"alt"),"Global") if($comparison(#page were on,"=","Google")) { then { log("Webpage is Google.com") } else { log("Webpage is NOT Google.com") } } activity("Webpage Check Complete!") purpose("Search For Term \"Turtle\"") type text(<name="q">,"Turtles","Standard") click(<name="btnG">,"Left Click","No")
Running the script logs two purposes within this script:
1. Checking to make sure we are on the correct page 2. Performing a search for the keyword "Turtle"
When the log files are viewed, the following logs are found for the entirety of the script:
2015-02-15 14:15:33 [PURPOSE] Check to Make Sure Webpage is Google.com 2015-02-15 14:15:33 [ACTIVITY] Beginning Webpage Check... 2015-02-15 14:15:33 [LOG] "Webpage is Google.com" 2015-02-15 14:15:33 [ACTIVITY] "Webpage Check Complete!" 2015-02-15 14:15:33 [PURPOSE] Search For Term "Turtle"