MathGroup Archive 2002

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: portable issues with zip files

  • To: mathgroup at smc.vnet.net
  • Subject: [mg38523] Re: portable issues with zip files
  • From: Bill Rowe <listuser at earthlink.net>
  • Date: Fri, 20 Dec 2002 23:40:43 -0500 (EST)
  • Sender: owner-wri-mathgroup at wolfram.com

On 12/20/02 at 4:24 AM, pmhowe at lanl.gov (Philip M. Howe) wrote:

> Some of the notebooks come through as Mathematica files,
>some come through as text files. For example, at David Park's website,
>the folder "ConicSections.zip", when unzipped, yields two Mathematica
>notebooks, "ConicSections.m" and "BrowserCategories.m". The rest of
>the files, even those with .nb endings, are text files. Mathematica
>(version 4.2) typically cannot open the text files. 

You don't state what version of the Mac OS you are using nor how you are trying to open the files. From you comments above I suspect you are using Mac OS 9.x or earlier.

Mathematica files are text files. So, it makes no sense whatever to say Mathematica cannot open text files.

>I then either 1. Drag the text file to an application downloaded from
>Wolfram, "Text to Mathematica", which immediately converts the file to
>a Mathematica notebook, or 2. Open the file in Microsoft Word, save it
>as a text file, and then reopen it with Mathematica, which converts it
>to a notebook. 

For Mac OS 9.x and earlier, files are identified as text files by having a filetype of 'TEXT'. This mechanism of identifying files is unique to the Mac OS. Consequently, there is no way for files created on a PC to have the correct filetype information. 

If you are using StuffIt Expander *and* you have file mappings set correctly using InternetConfig (Internet preferences in Mac OS 9.x) then StuffIt Expander will supply the correct filetype and file creator information and you should have no problems whatever. If you do not have an entry for .m or .nb the filetype gets set to a default string which will not be 'TEXT'. When this happens, no application on Mac OS 9.x or earlier sees the file as a text file.

OTOH, some Mac applications are written so that they can 'see' and open any file regardless of the contents of the filetype string.  From your comments, Word is apparently written in this manner. When you save the file as text from Word, it sets the filtype string to 'TEXT'. Once this is done, all other applications including Mathematica will see the file as a text file and treat it accordingly.

For the record, I am using Mathematica vers 4.2 on a Mac running Mac OS X currently. I have had no trouble openning any of the files from David Park's website directly (after unzipping them) in Mathematica without going through the steps you outlined above.


  • Prev by Date: Re: Package function variable hiding.
  • Next by Date: Re: Cox partial likelihood function, how to solve?
  • Previous by thread: RE: portable issues with zip files
  • Next by thread: Re: portable issues with zip files