MACSCRPT Archives

April 2008

MACSCRPT@LISTSERV.DARTMOUTH.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Steve Alex <[log in to unmask]>
Reply To:
Macintosh Scripting Systems <[log in to unmask]>
Date:
Tue, 29 Apr 2008 13:41:43 -0500
Content-Type:
text/plain
Parts/Attachments:
text/plain (30 lines)
Been a while since I've messed with applescript, but have tons of them  
laying around that are used almost every day.

I ran into a problem with one that is basically a data mining script  
that had not been used in a while. It is a drop script that opens a  
print file from an ancient accounting system and parses the file  
extracting out some data and puts it into a tab delimited import file.  
(using read/write in standard additions)

The original drop application was classic, but now running on Intel.  
Compiled and saved it with no problem. When we tried to import the  
file (to filemaker pro) we started to see some strange stuff.

Come to find out that on the system of the person I wrote the script  
for, every character that it writes out is proceeded by a Null  
character. Opening in text wrangler and showing invisibles shows all  
the nulls. This was on a MacBook Pro running Tiger. On my machine  
(intel iMac running Leopard) it works fine - no null characters.

Most of the data extracted is using some form of "Set foo to  
characters 4 thru 12 of bar as string". Text item delimiters set to "".

Almost seems some setting on his machine in making at act like UTS-16.  
Text Wrangler/BBedit reports it as US Roman/Mac.

Any ideas? Did not check archives since I can't seem to find them.

Steve Alex
AIDT

ATOM RSS1 RSS2