• 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: OS X 10.3.x, Address Book, and initWithVCardRepresentation
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: OS X 10.3.x, Address Book, and initWithVCardRepresentation


  • Subject: Re: OS X 10.3.x, Address Book, and initWithVCardRepresentation
  • From: Stefan Pantke <email@hidden>
  • Date: Fri, 5 Mar 2004 00:40:45 +0100

Greg,

I didn't used this feature (vCard), but I suppose, the UID is not required the create a new
person, since UID are not guaranteed to be unique across systems - unless you transfer
your whole AB from some backup media to the new AB. Thus, it seems useless for me to transfer the
UID from one system to another system.

I think, the only useful way would be to define a custom field, store the remote UID
in this and then save the record in the local AB.

In my app, ABPersons are created without UIDs and they can be added to the local AB perfectly well
running 10.2 and 10.3.

But: May the problem due to the slightly changed AB internal structure? AB 10.2.x and 10.3.x
differ in some fields which are new in 10.3.x records.

Stefan


Am 04.03.2004 um 22:29 schrieb Greg Anderson:

I'm not sure if this is a bug or if things just changed between 10.2.x and 10.3.x, but ...

My app transfers AB records in VCard format over the network, and then adds them to the Address Book if need be. I was testing it with one computer running 10.3.2 and one running 10.2.8 and the 10.3.2 machine kept crashing when it tried to add a new person to the AB.

It turns out that on 10.2.8, when I do the ol' [[ABPerson alloc] initWithVCardRepresentation:myData] autorelease], it makes an ABPerson record that the ABAddressBook likes. But on 10.3.2, that same code produces an ABPerson record without a UID. Try addRecord-ing that to your shared Address Book and it chokes with a bad access error, I'm guessing while trying to access the UID it's looking for.

I could just alloc and init an ABPerson and then cycle through the properties from the VCard and add all the property info I can find, but that doesn't seem right. Is -initWithVCardRepresentation alone no longer sufficient to create a valid ABPerson (and if so, shouldn't it not have "init" at the beginning anymore?) or is this a bug (in which case I'll head over to the bug reporter).

Thanks.

Greg

---
Greg T. Anderson
Mac Geek
http://homepage.mac.com/torgo
_______________________________________________
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.
_______________________________________________
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.


  • Follow-Ups:
    • Re: OS X 10.3.x, Address Book, and initWithVCardRepresentation
      • From: Finlay Dobbie <email@hidden>
    • Re: OS X 10.3.x, Address Book, and initWithVCardRepresentation
      • From: Greg Anderson <email@hidden>
References: 
 >OS X 10.3.x, Address Book, and initWithVCardRepresentation (From: Greg Anderson <email@hidden>)

  • Prev by Date: Re: Switching out an NSTextField's NSTextStorage
  • Next by Date: Re: compression...
  • Previous by thread: OS X 10.3.x, Address Book, and initWithVCardRepresentation
  • Next by thread: Re: OS X 10.3.x, Address Book, and initWithVCardRepresentation
  • Index(es):
    • Date
    • Thread