HEXEDIT

PURPOSE   OPERATION   OPTIONS   COMMAND LINES   RELATED PROGRAMS


Author: Dan Mares, dmares @ maresware . com
Portions Copyright © 1998-2021 by Dan Mares and Mares and Company, LLC
Phone: 678-427-3275

top

PURPOSE

The purpose of HEXEDIT is to allow the viewing and editing of files in both ASCII or HEX mode. Hexedit displays 25 characters per line and 20 lines per page/screen.

HEXEDIT is one of the few hex file editors that will run from DOS or in a DOS window on WIN9X or NT. Currently the 16 bit version has a file size limitation of 2 gig. (which is the DOS file size limit).

One anomaly when working within a DOS box (window) under Windows 9X. If the DOS window is not full screen, because of the way the graphics are designed, the DOS window is made to run full screen while the program is running. When the program ends, the properties of the DOS/Command Prompt window have been changed to full screen. If you want the DOS window to not be full screen the properties have to be adjusted. Sorry, this isn't me, its WIN9X allowing this to happen. (this doesn't happen under NT).

NOTE: when help screens are displayed, up and down arrows scroll the text within the help window. Return or Escape will generally exit the help screens.


top

OPERATION

The user starts HEXEDIT by entering the command followed by the name of the file to edit (C:>hexedit thisfile). Currently there is only one option available, the -s option will initiate a search string.

If the file being edited is set to READONLY the user is prompted to allow the program to alter the attributes in order to make modifications. If the user answers 'Y'es, the program will alter the files attributes and allow editing. When HEXEDIT is exited, the file being edited is set back to the original attributes, and the original file date and time are restored.

If the user answers 'N'o and does not wish to allow writing to the file, then the file is opened only for viewing, and no editing takes place.

HEXEDIT will display the file in both hexadecimal and ASCII characters. Those ASCII characters not capable of being printed (i.e. carriage return, NULL, and HEX FF) are displayed as dots (.) in the ASCII window. Most other characters are displayed with their graphic equivalent.

The data is displayed in two side by side windows displaying 25 characters per line by 20 lines per screen. The left being the hex and the right being the ASCII representation of the characters. A highlighted cursor allows for easy association of the two sides of the screen.

Directly under the display is a minimal help screen, and below that is a display indicating the current cursor location with respect to the current screen position, the current file location, name, and filesize.

Normal cursor movement is accomplished by the traditional use of arrow keys, the home, page up and down, backspace, the return/enter key, and the F2 and F3 keys (F1 gets help). Normal widow colors are yellow over blue, and highlighted characters are red.

The following keys have special meaning to the program.

F1: ==   Display the complete help screen. (ESC key exits help)
F2: ==   Go to first byte of the file.
F3: ==   Go to the end of the file. 
If the file is not divisible by 25, then after the last character you will see <<EOF>>->->-> until the end of the screen. The cursor will normally not go there, but in some file positioning commands to a new screen, it may show in this NoMans land. It is harmless and once moved off the area, can't be positioned back there.
F4 or ^F: ==  Enter string to find or search for.
F5 or ^L: ==  If search was successful, repeat last search. 
NOTE: the repeat last search will keep cycling through the file and back to the beginning and around. It keeps retracing its steps until the user stops hitting the F5 key.
F8: == Send current screen to a file for later printing. This is different from ^W. This option includes all the positional information and hex and ascii windows, whereas the ^W writes the data to the file.
^B: == Indicates the start of a marked block. (which will be followed by ^E).
^E: == Indicates the end of the marked block. At the time the ^E is entered, the user is asked for a filename to write the block to. The ^B SHOULD be entered before the ^E or results are undefined. 
^G: == User is asked for a file position to move (GOTO) to.
^W: == When editing a screen, the ^W immediately prompts for write verification of the data. If the file already exists the user is prompted to overwrite, append or abandon the operation.

Return key: == Move screen display down one line.
Page UP:    == Go up (back) one screen. 
Page DN:    == Go down to next screen.
Home key:   == Go to first character of the screen.
End key:    == Go to last character of the screen.
UP, DN, Right, LEFT arrows move in the traditional manner.

The escape key will generally get you out of the mode or help screen you are in. Depending on the mode and operation being performed, the escape key may also end the program.

EDITING MODE:

To enter or edit new information on the screen, just begin entering text at the cursor location. Any keys except the special keys mentioned above will be entered into the screen. If unprintable characters are needed, enter HEX edit mode by using the TAB key. You must then enter 2 hex digits for each character. There is no error checking, so if incorrect hex digits are entered the results are unpredictable. When you are finished entering the hex values, to get back to ASCII edit mode, enter the TAB key again. The TAB key toggles HEX/ASCII. When finished entering text, the ^W can be used to write the changes to the file. OR:

If the user gives any command to go to another screen, or enters text past the end of the screen, before the next screen is displayed, the user is reminded the data has been altered, and is asked to confirm the write back to the file. Any key EXCEPT a Y will ignore the changes. ONLY THE 'Y' WILL WRITE THE DATA BACK TO THE FILE. The screen will then be updated and moved as necessary.

^C (control C) will Immediately EXIT the program at any time.


top

COMMAND LINE

C:> Hexedit

/* gets help screen */

C:> Hexedit  -?

/* gets help screen */

C:> Hexedit  filename    

/* edits file called filename */


top

OPTIONS

-s + string:   Enter the string of characters to search for if immediate search is needed. Else, use F5 during program operation.

-?:   Get the help screen


top

RELATED PROGRAMS

Norton Diskeditor

Drivespy

top