IE Connector methods

  • Release version: Xanadu
  • Updated January 30, 2025
  • 3 minutes to read
  • Summarize
    Summarized using AI
    This content was generated using new OpenAI-powered functionality. Results are provided on an as is basis and are not guaranteed to be accurate or complete.

    Summary of IE Connector methods

    The IE connector methods enable automation and interaction with Internet Explorer browser elements, screens, and the connector itself. These methods are organized across three levels—connector, screen, and element—allowing ServiceNow customers to perform a variety of tasks such as navigating web pages, manipulating browser windows, interacting with web page elements, and executing custom scripts. Proper configuration steps are required to expose and utilize these methods effectively.

    Show full answer Show less

    Connector level methods

    Connector level methods provide control over browser navigation and status checks. Key capabilities include:

    • Navigate: Opens a web page by URL, returning a Boolean to indicate success.
    • WaitForAnyScreen: Waits for a screen to load with configurable timeout.
    • IsReady: Checks if the website is ready to accept requests.
    • IsCreated: Verifies if a website is open and optionally if all elements match.
    • Refresh, SaveAs, Print: Manage page content by reloading, saving locally, or printing.
    • Minimize, Maximize, Hide, Restore: Control browser window visibility and state.
    • GetURL, GetTitle, GetPageSource: Retrieve URL, window title, or full page source as strings.
    • GetScreenShot: Capture a bitmap screenshot of the window or a specific area.
    • Close: Closes the active browser window.

    Screen level methods

    Screen level methods are designed to interact with web page elements and perform actions such as data extraction, file downloads, and input simulation. Notable methods include:

    • DownloadFile: Downloads a file from the current screen using specified URL and filename.
    • ExecuteJavaScript: Runs custom JavaScript on the open page after configuring the script and parameters.
    • GetValueByXPath and GetValuesByXPath: Extract data using XPath expressions, returning strings or data tables respectively.
    • SetFields: Sets data into form fields after configuring the target elements and data types.
    • SendKeys: Simulates keystroke inputs with options for delay and matching child elements.
    • WaitForCreate: Delays actions until the page or window has loaded.
    • GetFields: Retrieves data from form elements, requiring prior configuration.
    • Focus: Brings a background or minimized window to the foreground.
    • MatchChildren: Checks if all captured elements match, returning a Boolean.

    Element level methods

    Element level methods apply to specific elements within the web page and include:

    • Click: Performs a click action on the selected element.
    • GetInnerHTML, GetOuterHTML, GetInnerText: Retrieve the HTML content or inner text of the element as strings.
    • GetURL: Obtains the URL associated with the element.

    Practical application for ServiceNow customers

    By leveraging IE connector methods at different levels, ServiceNow customers can automate Internet Explorer browsing tasks, extract data efficiently, interact with web forms, and control browser windows programmatically. Configuring these methods correctly ensures robust automation workflows in scenarios involving legacy Internet Explorer-based applications, enabling streamlined data integration and process automation within ServiceNow environments.

    The IE connector methods perform different tasks on the IE connector, screens, and the elements on the screens. The methods are available at the connector, screen, and the element levels and you can expose the methods by completing appropriate steps.

    IE connector method levels

    Connector level methods

    Screen level methods

    Element level methods

    Connector level methods

    Navigate

    Opens a web page based on the URL you specify and returns the Boolean response.
    Input
    URL
    Output
    Return (Boolean)

    WaitForAnyScreen

    The method executes a wait period before a screen loads up. You can specify a timeout after which the method times out the request.

    Input

    MatchAllChildren

    Timeout

    Screen level methods

    DownloadFile

    Downloads a file from the screen or web page based on the URL and file name you specify.
    Input
    Url
    fileName
    Output
    Return (Boolean)

    ExecuteJavaScript

    Executes custom JavaScript on an application or website open on the IE browser. You must configure the method before executing.

    To configure the JavaScript, do the following steps.
    1. Click the method settings icon (Method settings icon.).
    2. Enter the custom script under the JAVA SCRIPT section.
    3. To add parameter to the script, click the add parameter icon (Add parameter icon.) under the PARAMETER heading.
      Note:
      A Data In port is added with each parameter.
    4. Click OK.
    Input
    Parameter
    Output
    Return (Object)

    GetValueByXPath

    Converts an XPath and returns the output as a string.
    Input
    XPath (String)
    Output
    Return (String)

    GetValuesByXPath

    Returns the values within columns based on the specified XPath expression.

    Input

    You must configure the XPath expressions before executing the method. To configure, do the following steps.
    1. Click the method settings icon (Method settings icon.).
    2. Update the name of the column.
    3. Define the XPath expression.
    4. Click OK.

    Output

    Returns the data table after the operation.

    Hide

    Hides the active browser window.

    Restore

    Restores the browser window hidden using the Hide method.

    GetURL

    Returns the URL of the website or web page.

    Output

    Return (String)

    WaitForCreate

    Sets a delay before a web page or a window loads.

    Inputs

    timeoutInSeconds

    MatchAllChildren

    Outputs

    Return (Boolean)

    SetFields

    Sets the data in form field types.

    SendKeys

    Simulates the keystrokes on web pages and windows.

    Inputs

    Keys

    MatchAllChildren

    TypeDelay

    Minimize

    Minimizes the window.

    Maximize

    Maximizes the window.

    IsReady

    Returns the Boolean response to the request to check whether the website is ready to accept requests from methods.

    Output

    Return (Boolean)

    MatchChildren

    Matches all elements of a web page that you have captured and returns a Boolean response accordingly. You can configure whether the method should match all children.

    Input

    matchAllChildren

    Output

    Return (Boolean)

    IsCreated

    Returns the Boolean response to the request to find whether a website on an Internet Explorer browser is open. You can optionally have the method check whether all captured elements of the website matches.
    Inputs
    MatchAllChildren
    Output
    Return (Boolean)

    Refresh

    Reloads the contents of the active web page.

    SaveAs

    Saves the active web page to the local disk.

    Print

    Prints the active web page in the browser.

    Input

    NoPrompt

    GetPageSource

    Returns the page source of the active window open on the IE browser.

    Output

    Return (String)

    GetScreenShot

    Returns the screen shot of a window or area in a window.

    Output

    Return (Bitmap)

    GetTitle

    Returns the title of a window open in the IE browser.

    Output

    Return (String)

    GetFields

    Accesses data in the forms returns the data as output. You must configure the method before executing.

    To configure, do the following steps.
    1. Click the method settings icon (Method settings icon.).
    2. Select the form elements.
    3. Update the form element data type.
    4. Click OK.

    Output

    Form field

    Focus

    Sets the focus on a window that is running in the background or minimized and makes it active.

    Output

    Return (Boolean)

    Close

    Closes the active window.

    Element level methods

    These methods are exposed when you double-click an application element under the Global Objects in the Project Explorer.

    Click

    Performs a click operation on the element.

    GetInnerHTML

    Gets the inner HTML of the element.

    Output

    Return (String)

    GetInnerText

    Gets the inner text of an element.

    Output

    Return (String)

    GetOuterHTML

    Gets the outer HTML of the element.

    Output

    Return (String)

    GetURL

    Gets the URL of the element.

    Output

    Return (String)