User Tools

Site Tools


transformations:runprogram

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
transformations:runprogram [2016/09/20 23:20] dmitrytransformations:runprogram [2016/09/20 23:22] dmitry
Line 14: Line 14:
 ===Capturing output=== ===Capturing output===
 It is possible to capture STDOUT and STDERR of the executed external application or Windows shell command. For instance it is possible to run //dir// and capture its output as a table in EasyMorph, or forward output of an application into EasyMorph without creating a temporary intermediate CSV file. STDERR is captured in a separate column, which can later be used for error-handling routines. Since EasyMorph also outputs errors into STDERR this feature can be used for error handling of EasyMorph projects executed in the command line mode. It is possible to capture STDOUT and STDERR of the executed external application or Windows shell command. For instance it is possible to run //dir// and capture its output as a table in EasyMorph, or forward output of an application into EasyMorph without creating a temporary intermediate CSV file. STDERR is captured in a separate column, which can later be used for error-handling routines. Since EasyMorph also outputs errors into STDERR this feature can be used for error handling of EasyMorph projects executed in the command line mode.
 +
 +===Parameter substitution===
 +The transformation allows defining its command line as a text or as a calculated expression. It is possible to insert [[parameters]] into text. For instance:
 +
 +        copy /Y {SourceFileName} {DestinationFileName}
 +
 +The command line above is equivalent to the calculated expression below, but is easier to use.
 +
 + “copy /Y “ & {SourceFileName} & “ “ & {DestinationFileName}
 +
 +//SourceFileName// and //DestinationFileName// are parameter names.
 +
  
 ===See also=== ===See also===
 [[http://easymorph.com/learn/reusable-projects.html|Tutorial:Reusable projects and mass operations with files]] [[http://easymorph.com/learn/reusable-projects.html|Tutorial:Reusable projects and mass operations with files]]
transformations/runprogram.txt · Last modified: 2021/07/19 01:59 by craigt

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki