Copyright: Copyright ® 1994 P.M. Chefalo


Contents
  DOS/Unix Text Translator

Shareware from VB Expressions

Copyright © 1994 by P.M. Chefalo

DOS and Unix text files differ - by just a byte a line!  But that difference is enough to confuse some of the applications and editors in both environments.

The VB Expressions DOS/Unix Text Translator for Windows (TEXTTRAN, for short) will help you bridge the gap between these two computing environments by allowing you to convert between the formats inside the Microsoft Windows operating environment.

Overview

Installation

Operation

Watchouts!

Registration

To transfer from one topic to another, use the "Browse" button.

All Product Names Trademarks of Their Publishers. All rights reserved.


Overview of The DOS/UNIX Text Translator
Overview

Translating text files between the DOS and Unix environment was seldom an issue for standalone PCs or PC-centric  networks.  But in today's highly connected network world, PCs often have access to text files generated on Unix computers.  Unix boxes make excellent file servers for PCs, so your drive "U" may be a shared Unix volume;  and many PC users are "traveling" the Internet in an ever-expanding quest for the ultimate cyberspace wisdom.

Most Unix-based file service providers offer DOS/Unix translation utilities.  But these utilities most often are one-way: DOS-To-Unix or Unix-To-DOS;  they are DOS or Unix-based, not Windows;  they don't allow browsing to select files;  they don't offer conversion of multiple files in one pass;  they allow you to "double" up the translation, by running the software against the file more than once;  they don't check to see whether the files being processed are indeed text; and they don't offer a way to keep a back-up copy of the file being converted.

The VB Expressions DOS/Unix Text Translator for Windows addresses all these limitations in an easy-to-use, affordable utility.

The VB Expressions DOS/Unix Text Translator for Windows is a Visual Basic Professional Edition Version 3.0 application.  As such it requires the user to have the files VBRUN300.DLL and CMDIALOG.VBX to be available on the DOS path.   Its executable name is TEXTTRAN.EXE.

Installation Instructions.


"Unix", as used here, is a catch-all term for all the numerous operating systems based on AT&T's original creation.  Each vendor porting the OS has used its own name for its proprietary version of the software.

Therefore, we have AIX from IBM, Ultrix and OSF/1 from DEC, HP/UX from Hewlett-Packard, SunOS and Solaris from Sun Microsystems, A/UX from Apple, NeXTStep from NeXT, Irix from Silicon Graphics, Clix from Intergraph, Xenix from Microsoft, etc.  There really isn't any one operating system called "Unix" ... but as far as we at VB Expressions  know, all systems referred to as "Unix" share the same text file format.


Operations
Operation

Using VB Expressions DOS/Unix Text Translator for Windows is simple.  Click on each topic below for details:

Selecting Translation Direction

Selecting Files To Translate

Translating Files

Keeping Backup Files

Getting Help

Quitting Texttran


Installation

VB Expressions DOS/Unix Text Translator for Windows will normally be delivered with the executable, TEXTTRAN.EXE, this Help file TEXTTRAN.HLP and the required CMDIALOG.VBX support program compressed in one file.  The other required file, VBRUN300.DLL, the Visual Basic Version 3.0 runtime library, must be supplied by a third-party source, such as the on-line system, bulletin board or shareware distributor where you acquired the VB Expressions DOS/Unix Text Translator for Windows.  This policy was established because of the large size of the runtime library (almost 400k uncompressed) which makes it prohibitive to download it more than once - and once is all you need to run any of the many Visual Basic 3.0 applications.

Install VBRUN300.DLL and CMDIALOG.VBX in your \WINDOWS\SYSTEM directory.  If a later dated version of either file is already installed, it's best not to overwrite it.  (The Windows File Manager affords a convenient way to install these files.)

The executable, TEXTTRAN.EXE, can be installed in any directory. The Help file, TEXTTRAN.HLP, can be installed in any directory in the DOS path, but perhaps the best place for it is in the \WINDOWS directory.

TEXTTRAN.EXE can be started by double-clicking the file name in File Manager, or by setting up an icon in Program Manager or your favorite Windows shell.  See the shell documentation for advice.


Selecting Files To Translate

Click on the "Select File(s)" button, or enter an "Alt+S" keystroke, to open a dialog box to select files to translate.  Click on a file to select it, or enter its name in the edit box; to select multiple files, hold down the "Shift" key while clicking.  Of course, the multiple file selections must all be in the same disk directory.  If you type in the names, Windows will check for valid file names before you can leave the dialog box.

The selected file name will appear in the status area below the control buttons if a single file is picked; the message will read "Multiple Files Selected" otherwise.

Note: there is a limit on the number of files you can select in a multiple selection.  Due to limitations in the Windows 3.x Common Dialog File Open subroutine, a maximum of 2048 characters are returned for file paths.  This means the maximum number of files that can be selected is around 160 files (probably more, but around that number).  In the unlikely circumstances that you exceed the file limit, Texttran will ask you to re-select a smaller number of files.

If you select files again before translating, your previous selection is not saved, as is normal for Windows operations.

If you select a file that is marked "Read Only" by DOS, you will receive an error message asking you to re-select your files.

You must have access to the files through DOS file services to translate them: that is to say, a DOS file-name must be available.  This warning is made because, although Unix allows long file names, these cannot be processed by TEXTTRAN.


Translating Files

Click on "Translate", or enter an "Alt+T" keystroke to translate selected files.  If no file is selected, the program will alert you and ask you to select a file.

Then TEXTTRAN will check for non-text characters in each file.  If it finds any, it will ask whether to continue translation of the file.  Unless you know that the files selected are truly text, VB Expressions recommends that non-text files not be processed, so that their content is not inadvertently changed.

Next the DOS/Unix Text Translator will check to see whether any file already contains text formatted in the target environment.  If so, it will alert the user, then skip the file.

During file translation, the TEXTTRAN Window caption will change to "Translating..." and there will be a pulsing red "Translating..." status message in the status area below the control buttons.

You can switch to another application while TEXTTRAN is translating.  To avoid interrupting a translation and losing data,  the "Select File(s)", "Translate" and "Cancel" buttons are disabled while a translation is in progress.

VB Expressions DOS/Unix Text Translator for Windows can be iconized (minimized) while translating.  (Click the "Down Arrow" in the upper right, or select the "Minimize" command in the System Menu in the upper left, to minimize.)  The icon title will change back from "Translating..." to "DOS/Unix Text Translator" when translation is complete.

Note: if multiple files are selected with the same file name but different file extensions, and "Keep Backup" is checked, only the LAST will be preserved by TEXTTRAN; it overwrites the same file name without warning.

Note: that if a previously backed up version of the file is on the logged disk and directory, TEXTTRAN will overwrite it.  TEXTTRAN uses the "Filename.DOS" file name as its source file when translating a DOS file, and "Filename.UNX" file name as source when it translates a Unix file.  Rename your backups if you wish to retain them permanently.


Selecting Translation Direction
Selecting File Translation Direction

Selecting the direction of the translation is done by clicking on the options (radio) buttons on the TEXTTRAN form, or by entering the keystroke "Alt+D" to translate DOS files to Unix, or the keystroke "Alt+U" to translate from Unix text to DOS.

If you select the wrong direction, the DOS/Unix Text Translator will detect the problem and skip the translation.  Otherwise you would end up with double-spaced text in your source files.


Keeping Backup Files

Check the "Keep Backup" box or enter an "Alt+B" keystroke to cause the DOS/Unix Text Translator to keep a backup of the original file.  The file name will be the same, but the extension will be changed.  If the file was originally a DOS file, the backup's file extension will be ".DOS"; if the file was originally in Unix format, the new extension will be ".UNX".

Note: that if a previously backed up version of the file is in the logged disk and directory, TEXTTRAN will overwrite it.  TEXTTRAN uses the "Filename.DOS" file name as its source file when translating a DOS file, and "Filename.UNX" file name as source when it translates a Unix file.  Rename your backups if you wish to retain them permanently.

Note: if multiple files selected for translation have the same file name but different file extensions, and "Keep Backup" is checked, only the LAST file backup will be preserved by TEXTTRAN; it overwrites the same file name without warning.


Quitting Texttran
Quitting DOS/Unix Text Translator for Windows

Click the "Cancel" button to close TEXTTRAN, or enter an "Alt+C" keystroke.  As with all Windows applications, double-clicking on the System Menu (the box in the upper left corner) will also close the application.

Quitting the DOS/Unix Text Translator while it is translating is not a good idea; the file with the name originally selected is deleted at the start of the translation and rebuilt.  If you try to quit  Windows, or the TEXTTRAN application, during translation, you will be asked to confirm your decision.  If you must quit, the original file is still present as a backup.  See the naming convention explained in Keeping Backup Files.

To return to original browse sequence, select a destination below, or choose the "Contents" button.

Overview

Installation

Watchouts!

Registration


Getting Help

To get online Help for TEXTTRAN, select the "Help..." menu item, or press the F1 key.

The DOS/Unix Text Translator also supports context-sensitive Help - use the tab key to reach the interface element you want Help on, and press the F1 key, and this Help file will open to the appropriate section.


Watchouts!

We thought this would get the attention of the experienced Windows user, who might otherwise charge into TEXTTRAN without looking at the Help.  This info is in other sections, gathered here for emphasis.  See the Operations section for complete instructions.

During Installation: Install VBRUN300.DLL and CMDIALOG.VBX in your \WINDOWS\SYSTEM directory.  If a later dated version of either file is already installed, it's best not to overwrite it.

During File Selection: You must have access to the files through DOS file services to translate them: that is to say, a DOS file-name must be available.  This warning is made because Unix allows long file names, but these cannot be processed by TEXTTRAN.

During File Selection: There is a limit on the number of files you can select in a multiple selection.  Due to limitations in the Windows 3.x Common Dialog File Open subroutine, a maximum of 2048 characters are returned for file paths.  This means the maximum number of files that can be selected is around 160 files (probably more, but around that number).  In the unlikely circumstances that you exceed the file limit, Texttran will ask you to re-select a smaller number of files.

Before Translation: TEXTTRAN will check for non-text characters in the selected file.  If it finds any, it will ask whether to continue translation.  Unless you know that the files selected are truly text, VB Expressions recommends that non-text files not be processed.

During Translation: If a previously backed up version of a file to be translated is on the logged disk and directory, TEXTTRAN will overwrite it.  TEXTTRAN uses the "Filename.DOS" file name as its source file when translating a DOS file, and "Filename.UNX" file name as source when it translates a Unix file.  Rename your backups if you wish to retain them permanently.

During Translation: If multiple files selected for translation have the same file name but different file extensions, and "Keep Backup" is checked, only the LAST file backup will be preserved by TEXTTRAN; it overwrites the same file name without warning.

Quitting:  If you quit during translation, the file being translated will be incomplete.  TEXTTRAN will ask you confirm that you have to quit.


Registration
Registration Information

DOS/Unix Text Translator for Windows is a Copyrighted product of VB Expressions, 64 Burning Brush Drive, Rochester, NY 14606-4642.  Use without registration after 15 days trial is a violation of Copyright Laws.

To register VB Expressions DOS/Unix Text Translator for Windows for personal use, send $15 to:

VB Expressions

64 Burning Brush Drive

Rochester, NY 14606-4642

Kindly include the version number and the source where you got the VB Expressions DOS/UNIX Text Translator for Windows.  In return for your registration, you receive the right to continue to use the program; and a disk with the most recent version of the DOS/UNIX Text Translator for Windows, without the opening and closing "nag screen",  without the nagging "About..." screen on usage and with all necessary support files.  Please indicate the disk size required with your registration.

Registration also available for this software, delivered by E-mail, for $10.  Send your fee to the address above, and include your E-mail address.  You will not receive the disk, just the software, when registering in this manner.

For use in your business or government, please contact VB Expressions to negotiate registration fees. You can reach us by E-mail on CompuServe, ID 73457,3603 or AmericaOnline,  ScreenName PMChefalo.