• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: applescript-users digest, Vol 3 #1129 - 11 msgs
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: applescript-users digest, Vol 3 #1129 - 11 msgs


  • Subject: Re: applescript-users digest, Vol 3 #1129 - 11 msgs
  • From: Dannis <email@hidden>
  • Date: Tue, 10 Dec 2002 05:40:40 +0800 (CST)

hi Emmanuel:
Thanks for your response:) I've checked the API OSACompileExecute,
but there is not much relative description.
Obviously, I have to specify the location of my script file, where
the daemon can compile and then execute it. But I don't find any
API to do such thing.

The function prototype of OSACompileExecute is like the following:
OSAError OSACompileExecute (
ComponentInstance scriptingComponent,
const AEDesc *sourceData,
OSAID contextID,
SInt32 modeFlags,
OSAID *resultingScriptValueID
);

The second argument *sourceData is type of AEDesc* . API AEBuildDesc()
is used to create this type of object. The first three lines of my
script file content are :
tell application "Finder"
set theApps to name of every process whose visible is true
end tell
The content packed in a char array is passed to the third argument of
API AEBuildDesc(). But there's an error saying fErrorPos is 5 and
AEBuildErrorCode is aeBuildSyntaxNoEOF.
It seems that API AEBuildDesc() only creates the respective apple event
of a single statement.

Is there any convenient approach to compile the whole script file
and execute it ?

Dannis

>>At 8:28 PM +0800 08/12/02, Dannis wrote:
>>I have a daemon tool (c++ tool but not cocoa application ) and an
>>applescript file. My daemon would run the script file under
>>some situation. My question is that how to run the script
>>via my daemon ?
>
>Why wouldn't you call OSACompileExecute?
>
>Emmanuel
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.

  • Prev by Date: Re: another Quark scripting question
  • Next by Date: Re: unicode to text string
  • Previous by thread: Strange "bug": Scripting QT Player 6 and setting chapter tracks
  • Next by thread: Re: applescript-users digest, Vol 3 #1129 - 11 msgs
  • Index(es):
    • Date
    • Thread