Many years ago I started using Textpad as a replacement for Notepad. I soon discovered several features that made my life so much easier. I now don’t know what I would do without them. I’d be interested in hearing if there are any other similar products that include these features. Both features that I will describe here involve the “Find in Files” functionality.

The first aspect of the “Find in Files” function is the fact that Textpad will display the results of the search and clicking on each line brings you directly to the file and place in the file that the search text is found. The file is opened in a new tab so the search is still available. Before 5.0 the search results ended up in it’s own tab. In 5.0 the search results ends up in a special window at the bottom of the Textpad window.

The example that I’m using is searching a Dr. Watson file for “when:”. This let’s you see the frequency of abends on a PC that is having problems.. This search will result in a list of abends with the date/time of each abend. Double-Clicking on one of the search result entries will bring you right to the start of the Dr. Watson entry in the log file.

Find in Files dialog:

Results of searching a Dr. Watson log file (click image below for larger image):

The second example is useful when you need to replace something in several text files that you know is unique and safe to change.

  1. Using the “Find in Files”, do the same as the Dr. Watson search above except, instead of giving a specific file name, use wildcards.
  2. Pick the top level directory of the files you want to search
  3. Check the “Search subfolders” option
  4. The search results will contain all the lines that contain the search text.
  5. Right-click in the search results and click on “Open All”.
  6. All the files named in the search results will open up in seperate tabs.
  7. Use the “Replace” option under the “Search” menu to identify what to replace. Click the “All Documents” option and then click “Replace All”.
  8. The text will be replaced in all the files.
  9. Under the “Files” menu click “Save All” and “Close All”.It’s easy and fast.

If you can’t quite get something unique across all files you can do it several times using unique search criteria that meets your needs. The nice thing about doing it this way rather than a command line tool is that you can easily see how good your search is and whether or not it’s safe to really do the “replace all” before actually doing it.

One thing that I have found to improve my productivity is to migrate as much as I can to a USB flash drive. After adopting PowerBasic as the main language I use to write utility type of software, both GUI and command line, I decided to see how well it works from a flash drive. I use three Powerbasic products and a PB aware editor:

Total size on my USB drive is 30 MB. They are licensed so that you can use them on as many computers as you want as long as you can only use them on one at a time. By having them installed to my USB drive that insures that is true.

I find them very easy to use. Quick to launch, compile, debug, and run and I have them with me all the time. PowerBASIC makes small fast EXE’s with no runtime required. When an install is required I create one with Inno Setup.

I just noticed that TCI has been updated. It’s tough to keep up with new software releases. I hate it when a program that I use everyday gets updated with features I really want and I don’t catch that they’ve been updated. As much as I hate programs that phone home, I’ve gotten use to them. It looks like this was updated late last year.

TCI is sold by JP Software and it is called Tabbed Console Interface. What it does, is let you run multiple consoles in a single window with a tabbed interface. The new feature that I like is that you can preset the tabs that you want loaded when you start TCI.

I typically use 4NT for most of the command line stuff that I’m doing. I still need to test with the standard windows command shell (CMD.exe) if I’m creating something for a server or box that doesn’t have 4NT. I’ve also been trying out PowerShell to see if it is worthwhile for me to switch to it. Now I can load them all up at once. It is easy to attach to other consoles (ie. putty, cygwin, etc.) as you open them up and add them as tabs. I will usually end up with two TCI windows open with multiple tabs in each one.

Click image below for larger image: