You are here: Reference > JavaScript > client-side > browser > methods > AutoScan (external)

AutoScan method (external)

Browser support:
Attempts to find a Web site based on the specified domain part.
The AutoScan method iterates through the patterns located under HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Internet Explorer\Main\UrlTemplate in the system registry and creates URL addresses based on the patterns and the specified domain part (the '%s' substrings in the patterns are replaced with the specified domain part).
The AutoScan method tries to connect to the created URL in each step and if it succeeds, then stops the iteration and loads the page into the window identified by the third parameter. If no valid URL is found, it opens the page specified by the second parameter. The following patterns are specified in the system registry by default:
This method does not work in Internet Explorer from version 7 and raises an exception.


object.AutoScan (domainPart[, defaultURL [, target]]);
You can find the related objects in the Supported by objects section below.


Required. String that specifies the domain part.
Optional. String that specifies the location of the default page that will be displayed if no matching web site is found. If this parameter is not specified and no match is found, the default error page will be displayed.
Optional. String that identifies the target window where the page needs to be displayed.
One of the following values:
The name of a window, frame, or iframe.
Indicates a new window.
Indicates the HTML content area of the Media Bar.
Indicates the parent frame.
Indicates the browser search panel.
Default. Indicates the frame containing the source link.
Indicates the topmost window.

Return value:

This method has no return value.

Example HTML code 1:

This example illustrates the use of the AutoScan method.
    <script type="text/javascript">
        function FindPage () {
            try {
                window.external.AutoScan ("dottoro", "", "_blank");
            catch (e) {
                alert (e.message);
    <button onclick="FindPage ();">Find dottoro home page</button>
Did you find this example helpful? yes no

Supported by objects:

Related pages:

External links:

User Contributed Comments

Post Content

Post Content