• 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
Best way to get a file path for presentation to the user
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Best way to get a file path for presentation to the user


  • Subject: Best way to get a file path for presentation to the user
  • From: Graham Cox <email@hidden>
  • Date: Fri, 18 Dec 2015 20:24:20 +1100

Hi all,

I want to display a path to the user. I have a URL, I need to show the local file path that represents (it’s always a local file path), where the /Users/<username>/ is replaced by ~/

Is there an easy, reliable way to do this, or do I have to do a string search/replace myself? Going the other way is trivial, I know, but I don’t see anything that gives me a displayable path given a URL.

—Graham



_______________________________________________

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: Best way to get a file path for presentation to the user
      • From: Jens Alfke <email@hidden>
    • Re: Best way to get a file path for presentation to the user
      • From: Graham Cox <email@hidden>
  • Prev by Date: Re: Window position updates on demand?
  • Next by Date: Re: Best way to get a file path for presentation to the user
  • Previous by thread: Re: Window position updates on demand?
  • Next by thread: Re: Best way to get a file path for presentation to the user
  • Index(es):
    • Date
    • Thread