<

Search and Replace & External Editors

Search and Replace v 3.2+ has two places where an external editor of your choice can be used. Separate settings are possible for text and binary files. Please see the program F1 help for more information.

Text Files

Search and Replace can launch a text viewer/editor of your choice on an item in the Search Results list via the 'Open with Default Viewer' function under the View Menu or the right click context menu.

The command line to launch the default viewer is configured in the If no association use field in Options-General tab. The program defaults to using 'notepad.exe'. You can modify this to employ another program.

Two special switches are available: %line% and %path%. %line% will pass line number in the file where the search hit is found and %path% is the full path to the file highlighted in the search results list.

Consult the documentation for your viewer/editor for the command line switches that are understood by your program. It surely understands a file path for the file to open. However, not all programs have a command line switch for 'line to move to' upon opening a file.

Users of TextPad (Helios Software, www.textpad.com), Multi-Edit (American Cybernetics, www.multiedit.com), and UltraEdit (IDM Computer Solutions, www.ultraedit.com), and Notepad ++ (Sourceforge.net - notepad-plus.sourceforge.net/uk/site.htm) - Some sample settings for the 'If no association use' field in Options-General are:

If you are familiar with merging .reg files, SR_External_Editors.zip contains some sample .reg files you can use to merge into your registry. Read through the informational .txt file in that zip beforehand!

Binary Files

If Search and Replace determines that the file being searched is a binary file the Search Results list switches to displaying 'offset' information. If you have our freeware HexView installed in the same path as Search and Replace, double clicking on a line in the Search Results will use HexView to display the context. You can also easily configure FSHED.exe to be used. FSHED is another free hex editor by Funduc Software.

The command line to launch the default binary viewer-editor is configured in the Binary Editor field in Options-General tab.

Some sample command lines are:

HexWorkshop (BreakPoint Software, www.bpsoft.com):
   hworks32.exe "%path%" /GOTO:%start% /SELECT:%length%

Funduc Software FSHED hex editor:
   FSHED.exe "%path%" /s%start% /l%length%

Funduc Software HexView:
   hexview.exe "%path%" -S%start% -E%end%