commandexecutordocumentation
Differences
This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
| commandexecutordocumentation [2022/01/09 20:04] – created wikiadmin | commandexecutordocumentation [2022/01/09 22:02] (current) – wikiadmin | ||
|---|---|---|---|
| Line 5: | Line 5: | ||
| ===Introduction=== | ===Introduction=== | ||
| - | This manipulator is used to run a native command on the computer where MIX or the deployed TransSECS software is running. For example, to get a list of image png files in a directory, on Linux run "ls *.png -a -1" and on Windows the equivalent run in cmd "dir *.png /b". | + | This manipulator is used to run a native command on the computer where MIX or the deployed TransSECS software is running. For example, to get a list of image png files in a directory, on Linux run "ls *.png -a -1" and on Windows the equivalent run in cmd /c "dir *.png /b". |
| ===Using in MIStudio=== | ===Using in MIStudio=== | ||
| - | This Bean has two inputs which are used as triggers to run the command in the " | + | This Bean has two inputs which are used as triggers to run the command in the " |
| - | ===Using in a Script=== | + | {{: |
| + | The Output of this Bean is the text which would be generated if the command were executed in a command shell or terminal. | ||
| + | |||
| + | ===Run a Simple Command=== | ||
| + | |||
| + | <note important> | ||
| + | |||
| + | To get a list of png image files in directory C: | ||
| + | |||
| + | <code text> | ||
| + | cmd /c dir C: | ||
| + | </ | ||
| + | |||
| + | and connect a Button to the " | ||
| + | |||
| + | In Linux, the Command will be similar, but in this example we change to the images directory then get the list of png files in it: | ||
| + | |||
| + | <code text> | ||
| + | (cd / | ||
| + | </ | ||
| + | |||
| + | ===Running a .sh or .bat=== | ||
| + | |||
| + | You can use the Command Executor to run a Linux .sh or Windows .bat. Example commands for Linux and Windows are: | ||
| + | |||
| + | <code text> | ||
| + | | ||
| + | </ | ||
| + | |||
| + | <code text> | ||
| + | cmd /c start .\\reports\\run_report.bat | ||
| + | </ | ||
| + | |||
| + | ===Passing Parameters=== | ||
| + | |||
| + | An Array Value Object can be constructed (either by script or using a StringToArray, | ||
| ===Configuration=== | ===Configuration=== | ||
| - | **Connection Name**: Select the Database Connection Manager | + | **Command**: The command |
| - | **SQL Statement**: | ||
commandexecutordocumentation.1641776695.txt.gz · Last modified: by wikiadmin
