Decode AppleFile 1.1 - by Carl W. Bell
Copyright © 1995-1998 Baylor University
AppleSingle/AppleDouble Code © 1994 Christopher J. Newman.

Note: If you got here using a web search engine, you can find the program here.

Disclaimer: Although Decode AppleFile seems to work fine, it is distributed "as is". Use at your own risk.

Decode AppleFile is small utility that decodes AppleSingle, AppleDouble, and BinHex files. Although some, especially MacMIME capable, applications automagically decode AppleSingle, AppleDouble, and BinHex files, others do not and just give you one or more binary files. If you have a file that is still Base64 encoded and has the MIME headers, you should use a MIME decoding utility such as MPack or maybe YA-Base64 (?) to decode it. Decode AppleFile does not parse MIME headers. If you are currently using StuffIt Expander to decode BinHex files, keep using it. There's no reason to use this instead.

To decode an AppleSingle or BinHex encoded file:

Choose the "Decode AppleSingle/BinHex..." menu.
Select the encoded file you want to decode.
When asked, specify where to save the decoded file.

or

Drag and drop one or more files onto the Decode AppleFile icon.
The decoded files will appear in the same folder as the encoded files.

To decode an AppleDouble file:

Choose the "Decode AppleDouble..." menu.
Select the encoded file. (This is the "%" file.)
Select the data file to be appended. (This is the "non-%" file.)
When asked, specify where to save the decoded file.

You cannot decode AppleDouble files by dragging them onto the Decode AppleFile icon.

You can also decode files using AppleScript. Here's a quick and dirty example...

on run
  tell application "Decode AppleFile"
    activate
    set outputFile to decode file "Macintosh HD:Desktop Folder:encoded:SomeFile.hqx"
    -- set outputFile to decode file "Macintosh HD:encoded:%aFile" data fork file "Macintosh HD:encoded:aFile"
  end tell
  tell application "Finder"
    activate
    select outputFile
    move selection to folder "Macintosh HD:decoded"
  end tell
end run

The file will be decoded into the same folder with a unique name. The decoded file will be returned to you as the result of the decode statement so that you can do something with it. See the dictionary for official syntax. If you want to decode several (non-AppleDouble) files at once, you can use the standard "open" event but you won't get the decoded file back. Decode AppleFile is also recordable, by the way.

The AppleSingle code is based on source code originally by Chris Newman at CMU (MPack) (see below)

Release Notes:

1.1 2-Jun-98

1.1b2 12-May-98

1.1b 5-May-98

1.0 11-Dec-95

If you have any questions, comments, (constructive) criticism, or bug reports please let me know. You can contact me at the address(es) below.

-cb

Carl_Bell@baylor.edu
Carl Bell's Web Page
Stuff I've Written

Snail Mail:

Carl W. Bell
Academic and Research Computing Services
Baylor University Electronic Library
One Bear Place #97148
Waco, TX 76798
Phone:
(254) 710-4065
Baylor's Fine Print: This software, data and/or documentation contain trade secrets and confidential information which are proprietary to Baylor University. Their use or disclosure in whole or in part without the express written permission of Baylor University is prohibited.

This software, data and/or documentation are also unpublished works protected under the copyright laws of the United States of America. If these works become published, the following notice shall apply:

Copyright © 1991-1997 Baylor University
All Rights Reserved
The name of Baylor University may not be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE, DATA AND/OR DOCUMENTATION ARE PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.

When permission has been granted to make copies of this software, data and/or documentation, the above notices must be retained on all copies.

Permission is hereby granted for non-commercial use and distribution of Decode AppleFile.

Chris Newman's Fine Print:

/*
*
* (C) Copyright 1994 by Christopher J. Newman
* All Rights Reserved.
*
* Permission to use, copy, modify, distribute, and sell this software and its
* documentation for any purpose is hereby granted without fee, provided that
* the above copyright notice appear in all copies and that both that
* copyright notice and this permission notice appear in supporting
* documentation, and that the name of Christopher J. Newman not be used in
* advertising or publicity pertaining to distribution of the software without
* specific, written prior permission. Christopher J. Newman makes no
* representations about the suitability of this software for any purpose. It
* is provided "as is" without express or implied warranty.
*
* CHRISTOPHER J. NEWMAN DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
* INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT
* SHALL CHRISTOPHER J. NEWMAN BE LIABLE FOR ANY SPECIAL, INDIRECT OR
* CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
* DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
* TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE
* OF THIS SOFTWARE.
*/