MACSCRPT Archives

June 2009

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:
Stan Cleveland <[log in to unmask]>
Reply To:
Macintosh Scripting Systems <[log in to unmask]>
Date:
Thu, 4 Jun 2009 11:36:06 -0700
Content-Type:
text/plain
Parts/Attachments:
text/plain (19 lines)
On 6/4/09 7:30 AM, "Peter J. Hartmann" wrote:

> is there a coercion to convert a script object to text?
> Previously, it seems, it was possible to load a script from a file and
> coerce it to a string using "as string" or "as text".
> 
> Does not seem to work anymore.
> 
> Any clues?

Peter, if you're okay with calling a shell script, this works:

set scriptToDecompile to "Mac HD:Full:PathTo:TheScript"
do shell script "osadecompile " & quoted form of ¬
    POSIX path of scriptToDecompile

HTH,
Stan C.

ATOM RSS1 RSS2