add_incomingvalue_last_lineofscript
Differences
This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
| add_incomingvalue_last_lineofscript [2025/05/20 11:38] – created wikiadmin | add_incomingvalue_last_lineofscript [2025/05/20 13:52] (current) – [How to add incomingValue; to every script in a .tsx (TransSECS project file)] wikiadmin | ||
|---|---|---|---|
| Line 26: | Line 26: | ||
| } | } | ||
| incomingValue; | incomingValue; | ||
| + | </ | ||
| + | |||
| + | This is also OK (there is an output at the end) | ||
| + | <code text> | ||
| + | if (incomingValue.getQuality()==0) { | ||
| + | status=2; | ||
| + | } else { | ||
| + | status=-1; | ||
| + | } | ||
| + | status; | ||
| </ | </ | ||
| Line 31: | Line 41: | ||
| This is a change which was implemented in early 2024 so if you have old projects without this final " | This is a change which was implemented in early 2024 so if you have old projects without this final " | ||
| + | |||
| + | ===How to add incomingValue; | ||
| <note important> | <note important> | ||
| - | ===How | + | - Make a copy of your project tsx (as a backup) |
| + | - Exit TransSECS (TransSECS should not be running) | ||
| + | - On Windows use Notepad++ to load the project tsx. You can change the language to XML, but this is not necessary | ||
| + | < | ||
| + | |||
| + | ==First Pass: replace all existing " | ||
| + | |||
| + | - Use Ctrl-H | ||
| + | - Set up the Replace: | ||
| + | * Search Mode: Regular Expression | ||
| + | * Find what:< | ||
| + | * Replace with:< | ||
| + | - Execute the replace: Click Replace All | ||
| + | |||
| + | {{: | ||
| + | |||
| + | What this does is find any string(or just ;) with a ";" | ||
| + | |||
| + | |||
| + | |||
| + | ==Second Pass: add new incomingValue; | ||
| + | |||
| + | |||
| + | - Set up the Replace: | ||
| + | * Search Mode: Regular Expression | ||
| + | * Find what: < | ||
| + | * Replace with: incomingValue;</ | ||
| + | - Execute the replace: Click Replace All | ||
| + | - | ||
| + | {{: | ||
| + | |||
| + | On this last pass you can add a comment to the replacement line, such as incomingValue;< | ||
| - | | + | Note: the OK comment |
| - | 1. make a copy of your project tsx as a backup | + | |
| - | 2. make sure the project | + | |
| - | 3. On Windows use Notepad++ to load the project tsx. You can change the file type to xml if you like, but this is not necessary | + | |
| - | {{: | + | This procedure should help you modify projects using scripts in which there is no output at the end of the script. However, it is good to do a quick check of your project after these changes. Also there can be some casese where incomingValue; |
add_incomingvalue_last_lineofscript.1747755506.txt.gz · Last modified: by wikiadmin
