Command line options

Get help with installation and running here.

Moderators: DataMystic Support, Moderators, DataMystic Support, Moderators, DataMystic Support, Moderators

Post Reply
franknbeans
Posts: 17
Joined: Wed Aug 30, 2006 1:26 am

Command line options

Post by franknbeans »

I was wondering if TextPipe returns some sort of exit code or success/failure codes when ran from the command line. I ask this because I want to be able to write a script that prompts me for the "files to be filtered" location and then proceeds to programmatically or dynamically build my command line
-then,
I want to write my script to wait (for the return code) until that task is finished before launching a different filter/command line against the same group of files.

I realize this can be done in a batch (multiple filters) but I do not want the second filter to start unless I am sure the first one was finished successfully or there will be unpredictable results.

Also, I would use this method to do combinations of filtering such as:

filter all files in C:\filterone\*.*
(wait)
filter all files in C:\filtertwo\*.* (different fll file this time)
(wait)
merge all outputted files together (yet another fll file)
(wait)
filter/edit the merged file a certain way, etc (and yet another fll file)

etc.....

call me lazy but I am looking to further automate some processes I am currently doing with my new TextPipe Pro
User avatar
DataMystic Support
Site Admin
Posts: 2227
Joined: Mon Jun 30, 2003 12:32 pm
Location: Melbourne, Australia
Contact:

Post by DataMystic Support »

From the help file under Advanced\Exit codes.

TextPipe sets an exit code on completion that depends on the level of errors logged. Exit codes are useful for detecting program success from command line execution. You can use the DOS ERRORLEVEL command in a batch file to modify the execution flow according the exit code.
Highest logged error
Exit code
None
0
Info
1
Warning
2
Error
3

e.g. in a .BAT batch file.
textpipe.exe ....
IF ERRORLEVEL 3 do_something
IF ERRORLEVEL 2 do_something
IF ERRORLEVEL 1 do_something
franknbeans
Posts: 17
Joined: Wed Aug 30, 2006 1:26 am

Post by franknbeans »

I need to go back and re-read the chm file, must have overlooked that part - thanks
Post Reply