Code Completion

Overview

As of screen-scraper 5.0 a simple code completion has been added to the scripting. It is meant to make it easier to remember the method names and their parameters. It provides you with this information as well as a link back to the documentation on the methods.

Using Code Completion

To activate the dialog simply type the name of a built-in object followed by a period (just like you would when coding). If you pause after the period the dialog will pop up and allow you to click through the methods of the object. As you type it will limit the list until it gets to the one that you are looking for. By double-clicking on one, or hitting the tab key when it is selected, you will get the remaining code in your script with place holders for the parameters. Type in the values of the parameters and hit tab to jump to the next. When you are finished, the last time you hit tab it will jump to the end of the method call.

Macros

In addition to the code completion there are a number of built-in macros for common tasks. To active a macro simply type in its code and then hit the spacebar while holding down the Ctrl button.

Macro Codes

  • sv - Set a session variable.
  • gv - Get a session variable.
  • dp - Put a value into the dataRecord.
  • dg - Get a value from the dataRecord.
  • es - Manually initiate a script
  • sf - Manually initiate a file scrape.
  • log - Log a debug message.
  • err - Log an error message.
  • warn - Log a warning message.
  • info - Log an information message.
  • extract - Manually invoke an extractor pattern.
  • for - Setup a for loop.