add_incomingvalue_last_lineofscript
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| add_incomingvalue_last_lineofscript [2025/05/20 12:02] – 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 39: | Line 49: | ||
| - Exit TransSECS (TransSECS should not be running) | - 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 | - 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 " | ==First Pass: replace all existing " | ||
| Line 46: | Line 56: | ||
| - Set up the Replace: | - Set up the Replace: | ||
| * Search Mode: Regular Expression | * Search Mode: Regular Expression | ||
| - | * Find what: incomingValue\s*;\s*(</ | + | * Find what:< |
| - | * Replace with: incomingValue; | + | * Replace with:< |
| - Execute the replace: Click Replace All | - Execute the replace: Click Replace All | ||
| - | {{: | + | {{: |
| - | You should see a count on the bottom bar of this panel of how many original " | + | What this does is find any string(or just ;) with a ";" |
| - | ==Second Pass: add new incomingValue; | + | ==Second Pass: add new incomingValue; |
| - | - Set up the Replace: | + | |
| + | - Set up the Replace: | ||
| * Search Mode: Regular Expression | * Search Mode: Regular Expression | ||
| - | * Find what: (?< | + | * Find what: < |
| - | * Replace with: incomingValue; | + | * Replace with: incomingValue;</ |
| - Execute the replace: Click Replace All | - 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 | ||
| - | + | 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.1747756978.txt.gz · Last modified: by wikiadmin
