Skip to content

TestECMA2HostConnection.ps1 fails due to Internet Explorer dependency #38

@hoag-alam

Description

@hoag-alam

Description

The TestECMA2HostConnection.ps1 script fails on Windows Server systems with the error "The response content cannot be parsed because the Internet Explorer engine is not available, or Internet Explorer's first-launch configuration is not complete."

This is a critical issue for enterprise deployments as:

  1. Internet Explorer was officially retired and is rarely configured on modern Windows Server installations
  2. The script is essential for validating ECMA2Host connectivity during setup
  3. This blocks administrators from properly testing their ECMA connector configuration

Environment

  • Windows Version: Windows Server 2016/2019/2022
  • PowerShell Version: 5.1
  • ECMA2Host Version: Latest
  • Script Location: C:\Program Files\Microsoft ECMA2Host\Troubleshooting\TestECMA2HostConnection.ps1

Error Details

PS C:\Windows\system32> C:\Program Files\Microsoft ECMA2Host\Troubleshooting\TestECMA2HostConnection.ps1
cmdlet TestECMA2HostConnection.ps1 at command pipeline position 1
Supply values for the following parameters:
ConnectorName: CSV
invoke-webrequest : The response content cannot be parsed because the Internet Explorer engine is not available, or Internet Explorer's first-launch configuration is not complete. Specify the UseBasicParsing parameter and try 
again. 
At C:\Program Files\Microsoft ECMA2Host\Troubleshooting\TestECMA2HostConnection.ps1:65 char:17
+ ...     $resp = invoke-webrequest -uri $uri -headers $headers -Method GET ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotImplemented: (:) [Invoke-WebRequest], NotSupportedException
    + FullyQualifiedErrorId : WebCmdletIEDomNotSupportedException,Microsoft.PowerShell.Commands.InvokeWebRequestCommand

Root Cause

The script uses Invoke-WebRequest without the -UseBasicParsing parameter, causing it to depend on Internet Explorer's DOM parser.

Proposed Solution

Line 65 of TestECMA2HostConnection.ps1 should be modified from:

$resp = invoke-webrequest -uri $uri -headers $headers -Method GET

To:

$resp = invoke-webrequest -uri $uri -headers $headers -Method GET -UseBasicParsing

Alternatively, consider using Invoke-RestMethod instead of Invoke-WebRequest for better compatibility.

Workaround

Currently, administrators must either:

  1. Manually edit the script to add -UseBasicParsing
  2. Configure Internet Explorer first-launch settings via registry
  3. Use PowerShell 7+ if available

Impact

  • Severity: High - Blocks proper ECMA connector validation
  • Frequency: Affects all fresh Windows Server installations
  • Workaround Available: Yes, but requires manual intervention

Additional Context

This issue has been reported by multiple administrators and represents a significant barrier to ECMA2Host deployment. Given that Internet Explorer is deprecated, enterprise tools should not depend on it for basic HTTP operations.

The fix is minimal and would improve the deployment experience significantly.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions