• 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: A question on technique
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: A question on technique


  • Subject: Re: A question on technique
  • From: Shane Stanley <email@hidden>
  • Date: Wed, 18 Mar 2015 18:25:34 +1100

On 18 Mar 2015, at 10:06 am, Emmanuel LEVY <email@hidden> wrote:

Maybe interesting, the plist method is faster than any on my machine.

Emmanuel,

I've tried to add this method to my test script, but with no luck. Here's a simple script:

property Codes : {"94ae", "94d0", "942f", "9471"}
property Mnemonics : {"ENM", "ReW", "EOC", "RfX"}
property p : ""
set p to PlistNew
PlistSet p key Codes to Mnemonics
PlistGet p key "9471"

And it runs fine. But to use it in my test script, I obviously have to add:

use framework "Foundation"
use scripting additions

When I add that and try to run the script, I get an error on the PlistSet line:

--> error "The direct parameter of \"PlistSet\" must refer to an array or to a dictionnary." number -50

If I try it in Script Debugger, once I get the error, even removing those lines doesn't fix things -- I have to use a new document. That suggests the problem affects the whole scripting component (Script Editor uses a new component each time it compiles), which is not ideal.

(XMLLib 3.7.0 (build 370), which I assume is the latest.)

-- 
Shane Stanley <email@hidden>
<www.macosxautomation.com/applescript/apps/>

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

References: 
 >A question on technique (From: Gil Dawson <email@hidden>)
 >Re: A question on technique (From: Deivy Petrescu <email@hidden>)
 >Re: A question on technique (From: Deivy Petrescu <email@hidden>)
 >Re: A question on technique (From: "Stockly, Ed" <email@hidden>)
 >Re: A question on technique (From: "Stockly, Ed" <email@hidden>)
 >Re: A question on technique (From: Thomas Fischer <email@hidden>)
 >Re: A question on technique (From: Shane Stanley <email@hidden>)
 >Re: A question on technique (From: Thomas Fischer <email@hidden>)
 >Re: A question on technique (From: Emmanuel LEVY <email@hidden>)

  • Prev by Date: Re: A question on technique
  • Next by Date: Re: Timeout Not Working As Expected
  • Previous by thread: Re: A question on technique
  • Next by thread: Re: A question on technique
  • Index(es):
    • Date
    • Thread