After updating to Passolo 2016 it appears the using pslcmd.exe to run a macro does not work.

After updating to Passolo 2016 it appears the using pslcmd.exe to run a macro does not work. I have a very simple test macro that open a Passolo file and generates a target language file. From a command prompt window if I run "<APP PATH>pslcmd.exe /runmacro=<MACROPATH>\TestPSLCMD.bas" Passolo opens but does not do anything. The same command using Passolo 2011 opens the Passolo file and generates the target language file. Anyone experience this?

Parents
  • Anyone from SDL want to comment? Is this something you are aware of?
  • Hi Darrell,
    I've tested a sample macro and it works fine.

    Note that the macro needs to be located in the Passolo macros folder:
    C:\Users\Public\Documents\Passolo 2016\Macros
    and you don't need to specify the MacroPath.

    My command was:
    "C:\Program Files (x86)\SDL\SDL Passolo\SDL Passolo 2016\pslcmd.exe" /runmacro=PslReplaceProjectPathSelected.bas

    Kind regards,
    Adrian Maniu.
  • The msgbox macro works both ways (in Passolo and through runmacro).The sample macro I created generates 1 file. It works in Passolo 2016 but not through the macro alone.

    For my test I have a Passolo project with 1 file (EN) doing a generate to 1 language (FR)

    The macro code is
    Option Explicit

    Sub Main
    Dim prj As PslProject
    Dim trn As PslTransList
    Set prj = PSL.Projects.Open("C:\Samples\Test_PSL_CMD.lpu")

    PSL.Visible = False
    If Not(prj Is Nothing) Then
    'Loop thru all selected translation lists
    For Each trn In prj.TransLists
    trn.GenerateTarget

    Next trn
    End If
    End Sub

    I have my sample files and a video I can upload somewhere for you to see. During the runmacro process in Passolo a dialog box comes up with a title "0%" and a cancel button. Nothing else happens to it.
  • Hi Darrell, It's work for me.
    The program run without modification.
    I did some modification to see
    '#Language "WWB-COM"

    Option Explicit

    Sub Main
    Dim prj As PslProject
    Dim trn As PslTransList
    Set prj = PSL.Projects.Open("C:\help v10\whatnew\whatnew.lpu")

    PSL.Visible = True
    If Not(prj Is Nothing) Then
    MsgBox "find project"
    'Loop thru all selected translation lists
    For Each trn In prj.TransLists
    trn.GenerateTarget

    Next trn
    Else
    MsgBox "no project"
    End If

    End Sub


    I put the macro file in in C:\Users\Public\Documents\Passolo 2016\macros\test_call_macro.bas

    I create a empty file test.bat on my desktop with

    "C:\Program Files (x86)\SDL\SDL Passolo\SDL Passolo 2016\pslcmd.exe" /runmacro=test_call_macro.bas
    pause
    It's working fine for me. :)
Reply
  • Hi Darrell, It's work for me.
    The program run without modification.
    I did some modification to see
    '#Language "WWB-COM"

    Option Explicit

    Sub Main
    Dim prj As PslProject
    Dim trn As PslTransList
    Set prj = PSL.Projects.Open("C:\help v10\whatnew\whatnew.lpu")

    PSL.Visible = True
    If Not(prj Is Nothing) Then
    MsgBox "find project"
    'Loop thru all selected translation lists
    For Each trn In prj.TransLists
    trn.GenerateTarget

    Next trn
    Else
    MsgBox "no project"
    End If

    End Sub


    I put the macro file in in C:\Users\Public\Documents\Passolo 2016\macros\test_call_macro.bas

    I create a empty file test.bat on my desktop with

    "C:\Program Files (x86)\SDL\SDL Passolo\SDL Passolo 2016\pslcmd.exe" /runmacro=test_call_macro.bas
    pause
    It's working fine for me. :)
Children