HOW TO: Using RegexSnippets
I was just chatting to Thomas about RegexSnippets and how I use it to test my regex's. I think that most people haven't cottoned-on to the fact that you can write test modules within RegexSnippets itself. To use the code IDE do the following:
- Open RegexSnippets
- From the Main Menu choose Tools | Test Scripts
- Paste in the code sample from my previous entry
- Press "Build and Run"
You can also save code snippets from within the code IDE by selecting File | Save As. The code snippet gets saved into the "Templates" list in the code IDE.
The most common way of using the code IDE is to generate patterns from the Main Form and then, when you've got the pattern working you can right click in the "Pattern" textbox and choose "Generate Template"; this will copy your current regex and source into a pre-defined Template. You can also create your own Templates by editing the Xml configuration file in "\My Documents\RegexSnippets\Templates.xml".
All of this stuff is pretty much covered in the Help | Readme file.