Regular expression class [1] regular expression application - replacement specified content to the end of the line [2] Regular expression application - Digital replacement [3] Regular expression application - Delete the specified character of each line of row [4] Regular expression application - replacement with half-way brackets [5] regular expression application - delete blank software skills class --------------------- --------------------------------- [6] Software Skills - Keyboard Records Note [7] Software Skills - Close the convenient method of the document tag [8] Software Skills - How to add a suffix prompt when EditPlus saves text files? [9] Software Skills - Tips Cannot find a solution to grammar files [10] Software Skills - Set Editplus Support Other Text, such as Korean [11] Software Skills - FTP Upload Settings [12] Software Skills - How Disable backup file function? [13] Software Skills - Add syntax files, automatic completion files, and clip file tool integration class ---------------------------- -------------------------- [14] Tool Integration - Compiler Integrated Example (Java, Borland C , Visual C , Inno Setup, NSIS , C #) Tool Integration - Let EditPlus debug PHP program [16] tool integration - to create a PHP debugging environment (2) [17] Integrate Editplus in WinPE
[1] Regular expression application - replacement specified content to the end of the line, such as the following two lines abc AAAAAAA123 ABC 444
I hope that each time "ABC" is encountered, the "ABC" and the content of "ABC" and the content to the end are finally replaced with: ABC EFG123 ABC EFG
Solve: 1 In the Replace Dialog, enter "ABC. *" In the lookup content, check the "Regular Expression" check box, then click the "All Replace" button, the symbolic meaning is as follows: "." = Match arbitrary Character "*" = match 0 times or more
Note: It is actually the regular expression, but it is just to organize some problems that have been raised. From the regular expression itself, you can quote thousands of special cases.
[2] Regular expression application - Digital replacement I hope to replace AsDadasDasd 789ASDASDSDADASD 789ASDASD to: Asdadas [123] Asdasdas [456] asdasdasd [789] asdasd
In the replacement dialog box, check the "Regular Expression" check box; enter "[0-9] [0-9] [0-9]" [0-9] [0-9] [0-9] ", without quotation marks" replacement to: "Inside input "[/ 0/1/2]", does not include the range range for you, then select Alternative.
In fact, this is also the usual case of regular expressions, "[0-9]" indicates any special case that matches between 0 to 9, and "[AZ]" indicates that the matching A to Z is repeatedly used. "[0-9]", indicating the three numbers "/ 0" representative of the continuous "[0-9]" corresponding prototype, "/ 1" represents the second "[0-9]" corresponding The prototype, according to such push "[", "]" as simple characters, indicates that "[" or "]" is added, if you enter "other / 0/1/2 other", the replacement result is:
Asdadas other 123 Other ASDASDAS Other 456 Other ASDASDASD Other 789 Other ASDASD
Functional enhancement (by jiuk2k): If you will find content "[0-9] [0-9]" change to "[0-9] * [0-9]", corresponding 1 or 123 or 12345 Or ... you can customize as needed
There are still a lot of related content, you can study your own grammatics for the regular expression.
[3] Regular expression application - Delete the specified character of each line of row because these characters appear in the line, so it is definitely unable to achieve a simple replacement, such as 12345 12653452345, you need to delete "345" at the end of each row Also, the usage of the express expression, in fact, carefully see the regular expression should be relatively simple, but since there is this problem, it has aware of the process, and the solution is resolved: In the Replace dialog box, enable " Regular expression "check box Input" 345 $ "in the lookup content," $ "" $ "indicates that if you match from the row, you can use" ^ "to implement, but EditPlus has another function that can be easily deleted. The lead character string a. Select the line B you want to operate. Edit - Format - Remove the line comment c. Enter the first character to clear in the pop-up dialog box, determine
[4] Regular expression application - Replace multiple lines with half-way brackets have the following code: