Skip navigation.

Another use for a Hex Editor

useful utilities
One small task I currently have is using small text files to feed a test simulation application. Each character provides either data or a setting of significance to the test. This means I need to read small text strings and count carefully to update the alphanumeric characters. If I’m off by a character, it can affect the test dramatically so I have to be very careful. It is a tedious but essential task. I tried importing the unformatted text into Excel but had no luck. I’ve tried reading and counting slowly in notepad but when I have a long string of zeroes, it can be easy to lose my place. I’ve been experimenting with my hex editor (since I sometimes need the hex value too) as a tool to help me read the strings and count the characters. The visual use of the grid makes counting easier for me. And the fact that the hex value appears on the same view is convenient.

jEdit

Thanks for the tip. I tried this and it worked well. I don't plan to install jEdit on the test PCs - in part due to my obsession of maintaining a known state with any test equipment. But I can use this tool on my production PC and move the files to test.

Unicode characters

You also have to consider whether your document contains unicode characters, if you are relying on the number of bytes in a string to determine its length you will ultimately fail if the AUT can handle unicode characters. If the application handles unicode characters but you want to count the number of bytes you may fail if you use an editor such as jEdit as it displayes the decoded text.

I use TextPad

Karen,

I am quite fond of a little shareware product called TextPad for all sorts of string and file manipulations.
It has a HEX mode but it also shows you the position of your cursor.

At one of my clients we started to use this in the test team and then the developers caught on and finally the client decided to spring for a site license after more than 30 people were using the tool.

Little tools like this make life so much easier.

Roland Stens
rstens@performancetester.com

another tool for this

You might try the jEdit text editor. It has a nice display of both line numbers and column numbers.

Comment viewing options

Select your preferred way to display the comments and click 'Save settings' to activate your changes.