- Posted by
- Just a quick one. Perform all operations on an.XML file in UE. if (UltraEdit.document.length > 0) { UltraEdit.insertMode(); if (typeof(UltraEdit.columnModeOff) == "function") UltraEdit.columnModeOff(); else if (typeof(UltraEdit.activeDocument.columnModeOff) == "function") UltraEdit.activeDocument.co...Posted in Scripts
-   Topics
-   Views
- Jaretin
Sep 12, 2014
- Here is a slow one. Works line by line and updates it. Working blocks of lines will improve speed. UltraEdit.insertMode(); UltraEdit.activeDocument.bottom(); var allLines = UltraEdit.activeDocument.currentLineNum; var sLineTerminator = "\r\n"; if (UltraEdit.activeDocument.lineTerminator == 1) sLineT...Posted in Scripts
-   Topics
-   Views
- Jaretin
Aug 23, 2013
- For small files use this script if (UltraEdit.document.length > 0) { // Define the environment for the script. UltraEdit.insertMode(); if (typeof(UltraEdit.columnModeOff) == "function") UltraEdit.columnModeOff(); else if (typeof(UltraEdit.activeDocument.columnModeOff) == "function") UltraEd...Posted in Scripts
-   Topics
-   Views
- Jaretin
Feb 15, 2013
- To be faster. // Is at least 1 file opened? if (UltraEdit.document.length > 0) { // Define the word pairs. var asWords = {}; asWords["TRUE"] = "FALSE"; asWords["FALSE"] = "TRUE"; asWords["rising_edge"] = "falling_edge"; asWords["falling_edge"] = "rising_edge"; asWords["signal"] = "variable"; asWords...Posted in Scripts
-   Topics
-   Views
- Jaretin
Oct 22, 2012
- Hi Mofi, I would normally agree to your point of view, but I tested the following codes against a file containing 3300 lines, each row containing 33 columns. if (UltraEdit.document.length > 0) { var d = new Date(); var myrun = "" + d.toLocaleString() + "\r\n"; // Define the environment for the scrip...Posted in Scripts
-   Topics
-   Views
- Jaretin
Feb 16, 2012
- Todo less comparisons you can use the following code: if (UltraEdit.document.length > 0) { // Define the environment for the script. UltraEdit.insertMode(); if (typeof(UltraEdit.columnModeOff) == "function") UltraEdit.columnModeOff(); else if (typeof(UltraEdit.activeDocument.columnModeOff) == "funct...Posted in Scripts
-   Topics
-   Views
- Jaretin
Feb 15, 2012
- //Create testcase UltraEdit.newFile(); UltraEdit.activeDocument.write('<\/end><first><second id="11"><note>22<para>\n'); var sFound= '(<\/end><first><second{1} id=".*?"><note>)([\\s\\S?]+?<para>)'; var sReplaced = 'test'; var sReplacedNote= '$1<para level="4" change="add" rfc="statement">' + sRepla...Posted in Scripts
-   Topics
-   Views
- Jaretin
Jan 18, 2012
- I think the find-function is buggy again. And as pietzcker said, your regexpFind is wrong, because the \ has to be escaped in the string. The following Code will work (not very nice, but it will do it). UltraEdit.insertMode(); UltraEdit.hexOff; UltraEdit.perlReOn(); if (typeof(UltraEdit.columnModeOf...Posted in Scripts
-   Topics
-   Views
- Jaretin
Jun 10, 2008
- Don't know what exactly you want. May this will help you. UltraEdit.insertMode(); UltraEdit.hexOff; UltraEdit.ueReOn(); if (typeof(UltraEdit.columnModeOff) == "function") UltraEdit.columnModeOff(); else if (typeof(UltraEdit.activeDocument.columnModeOff) == "function") UltraEdit.activeDocument.column...Posted in Scripts
-   Topics
-   Views
- Jaretin
May 20, 2008
- I have the problem too. i added a line to your script. var selTxt = UltraEdit.activeDocument.selection; UltraEdit.messageBox(selTxt); UltraEdit.activeDocument.write("[[[[[[[["+selTxt+"]]]]]]]]"); it is very funny, what is displayed in the messagebox. you may make a screenshot containing the messageb...Posted in Scripts
-   Topics
-   Views
- Jaretin
Jun 25, 2007
- The Problem is, that UltraEdit.activeDocument.selection returns a string, but you need an integer for UltraEdit.activeDocument.gotoLine. use the following code to get intLine var line = UltraEdit.activeDocument.selection; var intLine = parseInt( line );Posted in Scripts
-   Topics
-   Views
- Jaretin
May 09, 2007
- This works. var orgDoc; orgDoc = UltraEdit.activeDocument; orgDoc.top(); var i = 0; while (orgDoc.findReplace.find("lala")) { i++; } UltraEdit.getString("Found that many times: " + String(i),1); Don't know, what you are doing with the copy?Posted in Scripts
-   Topics
-   Views
- Jaretin
Apr 18, 2007