1. Home
  2. Using the Order box in custom captured App

Using the Order box in custom captured App

In the advanced section of captured apps, there is a section called “Order” with the following info tag:

This optional field is for advanced users only.

Use this field to specify the order of login if it is not username, password and submit

How is this section used?

Answer:

The “Order” box is used for login pages where the username and password fields may need to be filled in a special order, or if the username and password forms are located on separate pages (e.g. The username is entered first, then a second page is loaded with the password box).

Syntax Examples:

The Order is constructed as a syntax of an array of commands:

  • Example 1: 

[[“sleep”,”2000″], [“ups”]]

  1. Load the login page.
  2. Wait for page to load.
  3. Fill in the username, password and additional login ID boxes (as defined in the app properties).
  4. Click the submit button, or simulate the “Enter” key (as defined in the app properties).
    • (This is the default setting)
  • Example 2:

[[“fill”, “username”],
[“click”, “button#idOfNextPage”],
[“waitForNewPage”],
[“fill”, “password”],
[“submit”]]

    1. Load the login page.
    2. Fill in the username box.
    3. Click the button with the CSS selector value of “button#idOfNextPage”.
    4. Wait for the next page to load.
    5. Fill in the password box on the second page.
    6. Click the submit button.
  • Example 3:

[[“fill”, “username”],
[“sleep”, 500],
[“fillEnter”, “password”]]

    1. Load the login page.
    2. Fill in the username box.
    3. Wait 0.5 seconds.
    4. Fill in the password box and simulate hitting the “Enter” key.
  • Example 4:

[[“sleep”,5000],
[“fill”,”username”],
[“fill”, “password”], [“submit”]]

    1. Wait 5 seconds
    2. Load the login page.
    3. Fill in the username box.
    4. Fill in the password box.
    5. Click submit button. 
Notes:
  • The examples above have been indented for clarity, when entering them into the app configuration, they will be entered all on one line, e.g.:
    • [[“fill”, “username”], [“sleep”, 500], [“fillEnter”, “password”]]
  • If there are any special characters like “:” in the CSS selector sections in the Order field, they will need to be double-escaped by putting a double backslash “\\” in front of the characters. For example:
    • [[“click”, “input#idLoginForm\\:idLoginOption\\:1”],[“waitForNewPage”],[“fill”, “username”],[“fillEnter”, “password”],[“ups”]]
    • (If copying the selector ID from elements already detected by the CBE Infinite App Capture function, then there will already be one backslash in front special characters – these will still need the second backslash so that they get escaped twice in Order.)

Additional Commands:

Command Entry Action Performed
[“click”, “button#CSS_selector_id”] Do a mouse click on the element defined in the selector field.
[“click”, “button#CSS_selector_id1,button#CSS_selector_id2”] Do a mouse click on one of the elements (comma separated) defined in the selector field if exist.
[“waitForNewPage”] Wait for the next page to finish loading
[“goto”, “http://www.google.com”] Go to the specified URL
[“ups “]
  1. Fill in the username and password boxes (and “Additional Login Field” box, if defined).
  2. Disable auto-complete of the form
  3. Click the submit button.
[“sleep”] Wait for 80 milliseconds (default value)
[“sleep”, ###] Wait for the specified amount of time in milliseconds.
[“fill”, “field-name“] Fill in the defined box with the value defined in the app configuration. Accepted values of field-name are: (Case-sensitive)

  • username
  • password
  • corpId

These labels correspond to the “User Name”, “Password” and “Additional Login Field” boxes (as captured in the Advanced section of the app properties).

[“fillEnter”, “field-name“] Same as “fill”, only after entering the defined value, it will then simulate pressing the “Enter” key on the webpage.
[“fill”, “password”,{pbl:1}] or [“fillEnter”, “password”,{pbl:1}] the {pbl:1} tag is added if the password field is protected (if the password you enter is replaced with do_not_look_at_me_1)
[“submit”] Disable auto-complete of the form and click the Submit button (as captured in the Advanced section of the app properties).
[“waitForNewPage”, {“httpStatus”: “401”}] Wait for the next page(s) to load with the given HTTP status code. This is useful for pages with URL redirects.
[“header401”] Fill HTTP BASIC/NTLM username password information when prompted.
Updated on July 15, 2019