SDL PowerShell Toolkit

SDL is pleased to announce the availability of a beta version of the SDL PowerShell Toolkit.

The SDL PowerShell Toolkit is a set of modules using Windows PowerShell scripting technology and the Project Automation and Translation Provider APIs from the SDL Trados Studio Professional SDK. In a nutshell, the modules provide functions and sample code that you can re-use in your PowerShell scripts to automate SDL Trados Studio. They feature an initial set of code for use in typical Studio automation tasks such as creating a project, a translation memory or a package derived from a project. You can use these as a starting point for your own PowerShell-based efforts. It is assumed that the reader is familiar with Windows PowerShell as well as an initial understanding of the SDL Trados Studio SDK, in particular the project automation API.

Over time, we would like to see the development community develop further modules and helpful functions that we can share with each other.

Best regards, Ian

Ian Davies | Senior Product Manager | SDL | Language Technologies Division | +44 7826843819

Paul Filkin | RWS Group

________________________
Design your own training!

You've done the courses and still need to go a little further, or still not clear? 
Tell us what you need in our Community Solutions Hub

PowerShellToolkit.zip
Parents Reply Children
  • Hi Jan

    What I found out so far:

    CreateNew seems to work only if you have $packageOptions.RecomputeAnalysisStatistics = $true;.

    Then again, I had error messages about "could not create instance of translation provider sdltm.https://...." which in turn happens because the integrated Windows-auth does not work with providers in that format "sdltm.https://....", it seems the "sdltm." has to be removed.

    I resolved that by adding a local SDL-user on our server which is added in the script through

    $project.Credentials.AddCredential("sdltm.https://<URI>:443",$false,"user","pass");

    After opening the project-File, of course.

    In short: you have to work around a lot of quirks in those libs, it seems...

    Regards
    Markus

  • Hello, still writing here, although I suspect this hasn't much to do with powershell, but with updated SP2 API.

    Since I upgraded to SP2, projects with file-based TM comes out without any TM configured. I tried using the original example provided but with the same result as my code.

    Projects with server-based TM gets configured correctly. This line:

    $entry = New-Object Sdl.ProjectAutomation.Core.TranslationProviderCascadeEntry ($tmPath, $true, $true, $true);

    gives me an empty object wether $tmPath is a Correct path string or a Translation Provider Reference as per this page:

    producthelp.sdl.com/.../Index.aspx

    Should I install an updated SDK? Is there any release Notes about API in SP2?

    Thank you!