• 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: How to create a GUID?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to create a GUID?


  • Subject: Re: How to create a GUID?
  • From: "I. Savant" <email@hidden>
  • Date: Sat, 6 Sep 2008 17:55:56 -0400

On Sep 6, 2008, at 5:39 PM, Meik Schuetz wrote:

I feel kind of embarrassed to ask, but could someone lead me the way on how to create an globally unique ID (such as for example d73e066c-cc88-4d66-be42-94dc091bb571) ?


In addition to Mike's response, remember that Google is your friend ... and so is cocoadev.com. :-)

http://www.cocoadev.com/index.pl?IDentifiers

  At the bottom of the page, there's this:

- (NSString *)uuid
{
CFUUIDRef uuidRef = CFUUIDCreate(NULL);
CFStringRef uuidStringRef = CFUUIDCreateString(NULL, uuidRef);
CFRelease(uuidRef);
NSString *uuid = [NSString stringWithString:(NSString *) uuidStringRef];
CFRelease(uuidStringRef);
return uuid;
}


--
I.S.




_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: How to create a GUID?
      • From: "Finlay Dobbie" <email@hidden>
References: 
 >How to create a GUID? (From: Meik Schuetz <email@hidden>)

  • Prev by Date: Re: How to create a GUID?
  • Next by Date: Re: How to create a GUID?
  • Previous by thread: Re: How to create a GUID?
  • Next by thread: Re: How to create a GUID?
  • Index(es):
    • Date
    • Thread