Re: Display Model Name
Re: Display Model Name
- Subject: Re: Display Model Name
- From: Luther Fuller <email@hidden>
- Date: Thu, 15 Sep 2011 15:27:34 -0500
On Sep 15, 2011, at 11:12 AM, Luther Fuller wrote: On Sep 15, 2011, at 9:55 AM, Jeffrey Madson wrote: That script gives me even more ideas of some items to include in the main display window. How do you parse information out of the script results with Apple Script?
I was asking myself that question earlier today. Somewhere, I have a script that uses the -plist option to create a record via System Events. Reading the record is obviously easy. Would the -xml option for 'system_profiler' work the same way? I don't know. When I find my script, I will let you know.
I found the script and annotated it ...
set imageInfo to (do shell script "hdiutil info -plist ") tell application "System Events" set infoRecord to value of (make property list item with properties {text:imageInfo}) -- -- during development, you will have to also write infoRecord to a .plist file -- (probably on the desktop, so you you can trash it after use) -- and open the file in Property List Editor so you can see the -- structure of the record. -- end tell
Try it with the 'system_profiler' command with the -xml option. It may not work. I don't know.
|
_______________________________________________
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