Generate Java scripts

From Screen Scraper Studio
Jump to: navigation, search

You can generate JavaScript for your particular screen scraping and UI automation scenarios: scraping windows, rectangular regions, clicking controls, typing text etc. In our example below, the automation scenario is to scrape a region on the screen from an web app.

Here are the steps to follow to generate JavaScript for a particular screen scraping scenario.

  • First you have to click the Automation script link on the immediate screen scraping window (follow the pictures below for each explanation)


GenerateJava.png


  • On the next window you are asked to choose a name for the script. You can also set a hotkey (combinations like: CTRL+key, Alt+key or a simple key) to run the script at anytime after you save it.


GenerateJSname.png


  • Then you can decide on which selection mode to use in the script:
  1. Yes, I want to select a window/region|control when the script starts
  2. Just scrape the window that is active when the script starts
  3. No, the script should scrape the window/region|control I have just defined


GenerateJSselectionMode.png


  • Finally you can choose an output for the extracted text:
  1. Copy the extracted text to clipboard
  2. Save the extracted text to a file

Here you can also:

  1. Click the View code button to see the generated JavaScript for your scenario
  2. Save script and close
  3. Save script and run


GenerateSelectOutput.png


  • Now you can run the JavaScript or edit it before running.


GenerateJSrunScript.png


  • Here's what you should see when you click Edit script button


GenerateJSeditScript.png

Share your opinion


blog comments powered by Disqus
Personal tools
Namespaces
Variants
Actions
Getting started
API documentation
Support
Toolbox