Talk About Network

Google




Programming > Applescript > Re: read XML Fi...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 2 of 10 Topic 1503 of 1697
Post > Topic >>

Re: read XML File

by Jerry Kindall <jerrykindall@[EMAIL PROTECTED] > Sep 3, 2007 at 07:54 PM

In article <fbhm6i$lil$1@[EMAIL PROTECTED]
>, Philipp Kraus
<philipp.kraus@[EMAIL PROTECTED]
> wrote:

> How I can read a xml file with AppleScript? I need the ip attribute in 
> one variable, the iface and unx nodes in a list. Can I create "objects" 
> like list of networks-objects and of the network-objects I can get the 
> attributes like object-properties?

Is the structure you want to use set in stone, or would any XML-based
format work?  In the latter case, you can use the "defaults" command
line command, called from AppleScript using "do shell script".  There's
a specific XML format used for property lists (.plist files) and the
"defaults" command will read and write particular keys in it.

Otherwise, no, AppleScript, does not have an XML reader or writer.  It
would be pretty easy to write your own if you don't need strict
parsing, though.

-- 
Jerry Kindall, Seattle, WA                <http://www.jerrykindall.com/>

        Send only plain text messages under 32K to the Reply-To address.
        This mailbox is filtered aggressively to thwart spam and viruses.
 




 10 Posts in Topic:
read XML File
Philipp Kraus <philipp  2007-09-03 21:10:10 
Re: read XML File
Jerry Kindall <jerryki  2007-09-03 19:54:45 
Re: read XML File
Dave Balderstone <dave  2007-09-03 21:25:35 
Private Message
   2007-09-03 22:56:26 
Private Message
   2007-09-04 00:49:51 
Private Message
   2007-09-07 22:56:51 
Private Message
   2007-09-07 21:38:08 
Private Message
   2007-09-09 01:00:24 
Private Message
   2007-09-08 20:00:49 
Private Message
   2007-09-09 12:20:39 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
localhost-V2008-12-19 Mon Jan 5 18:56:33 PST 2009.