Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Help required with Shell Script please...



On Mar 30, 2007, at 6:44 AM, Nick Hearn wrote:
Please can someone help me. I'm trying to get a list of the names of custom print presets from this plist file 'com.apple.print.custompresets.plist'.

You don't need a shell script. Reading the contents of a plist file is best done like this ...


-- plistAlias is an alias to the file com.apple.print.custompresets.plist
tell application "System Events"
plistAlias as text
set plistRec to (value of property list file the result)
end tell


Of course, you will also need to know the structure of the record 'plistRec' so you can experiment with it. You will need the application "Property List Editor.app" located in /Developer/ Applications/Utilities/. (Install Developer Tools, if you haven't.)

You would think that you would be able to print from "Property List Editor.app" ... you can't!
You will have to take a picture of the upper pane. (Don't even touch the Dump button.)


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

This email sent to email@hidden
References: 
 >Help required with Shell Script please... (From: Nick Hearn <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.