Forum Discussion

mortenb123's avatar
mortenb123
Contributor
10 years ago

powershell JScript integration TC11 and winServer2012r2

Hi All

I'm new to testcomplete and I'm having problems getting powershell integration to work.

 

I've installed all the GACs with powershell and .NET4.5.X

 

I try the boilerplate examples:

https://support.smartbear.com/viewarticle/72616/

 

But this line always fails:

PowerShell = dotNET.System_Management_Automation.PowerShell.Create();

 

With the error:

'dotNET.System_Management_Automation_PowerShell' is null or not an object

 

I can use the simpler version using WScript.Shell, but the most scripts contains unlimited regexp parsing:

 

PS C:\dist\ps> .\readlog.ps1 -server test1-back-01.bptest.local -filter "OTP:\s\d{4}.*\+474750055011" -last 1 -timing

 

C:\bps\log\trace\bpregcmswebappserver_trace_20151029153427.log:3012:8:: 2015.10.30 13:34:20,965: Engangskode / OTP: 0608 phone: +4750055011
Timing: 00:00:00.5328338

 

 

Thanks

 

Morten Bjoernsvik, Oslo, Norway

 

  • In GAC list I finally found what I needed:

    System.Management.Automation version 1.0.0.0 and 3.0.0.0

     

    I must say the GAC selector has a terrible UI, just a list of similar names and no filtering.

     

  • In GAC list I finally found what I needed:

    System.Management.Automation version 1.0.0.0 and 3.0.0.0

     

    I must say the GAC selector has a terrible UI, just a list of similar names and no filtering.