• 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: Appending multiple dictionaries to a plist
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Appending multiple dictionaries to a plist


  • Subject: Re: Appending multiple dictionaries to a plist
  • From: "John Farmer" <email@hidden>
  • Date: Wed, 30 Apr 2003 07:25:06 -0700

----- Original Message -----
From: <email@hidden>
To: "John Farmer" <email@hidden>
Cc: <email@hidden>
Sent: Wednesday, April 30, 2003 12:41 AM
Subject: Re: Appending multiple dictionaries to a plist


That's essentially what I have done, when I write to the plist my structure
looks something like this:

<dict>
<key>profile name</key>
<dict>
<key></key>
<string></string>
.
.
.
</dict>
</dict>

My real problem seems to be when the user creates a new profile name in the
app, it will just overwrite the above structure with the new profile, not
append that profile after the preceding ones in the plist.. I am using
the [dict writeToFilePath:path atomically: YES]. I've tried to use both yes
and no for writing atomically, but it doesn't seem to make a difference.

>
> On mercredi, avril 30, 2003, at 12:16 AM, John Farmer wrote:
>
> > Greetings,
> >
> > I am working on a application that will allow a user to have multiple
> > profiles. My problem is that when I want to write a new profile to a
> > plist
> > file, it overwrites my old one. I have looked through the
> > documentation to
> > try to find a way to append this dictionary to the plist without
> > overwritting
> > the existing dictionaries... Does anyone have any suggestions?
>
>
> Embed your dictionary profiles in a dictionary whose keys are the name
> of the profiles and the related values the profile.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

References: 
 >Re: Appending multiple dictionaries to a plist (From: email@hidden)

  • Prev by Date: remove alpha channel from bitmap
  • Next by Date: Re: mounting idisk?
  • Previous by thread: Re: Appending multiple dictionaries to a plist
  • Next by thread: Re: Appending multiple dictionaries to a plist
  • Index(es):
    • Date
    • Thread