• 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 do I find my Application's directory?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How do I find my Application's directory?


  • Subject: Re: How do I find my Application's directory?
  • From: Scott Mitchell <email@hidden>
  • Date: Wed, 22 Jun 2005 13:38:54 -0600

Thanks.

No I don't want to do anything like that. I know better than that. I need to be able to create a folder in the same location
that our app is stored at. I should say where our App bundle is stored, not the actual exactable.


This is not the most ideal way to do this, but unfortunately this is the way it has been done for years, and
they don't want to change it on our users at this time.


Thanks again. I did not think about NSBundle.

Thanks,
Scott Mitchell
Macintosh Software Engineer
Excelsior Software
http://www.excelsiorsoftware.com

On Jun 22, 2005, at 1:29 PM, Finlay Dobbie wrote:

On 6/22/05, Scott Mitchell <email@hidden> wrote:
I am sure this is very easy but I can't seem to find an answer for it.
How can I find my applications directory that it was launched from?

Why do you want to know? Typically people asking this question want to access the application directory because either 1) They have resources stored there. This is bad. Resources should be stored inside the application bundle. or 2) Want to write a file there. This is bad. Your application might not have privileges to write to the containing folder.

Anyway, you can get the path using NSBundle and walk back up the
heirarchy from there, should you find it absolutely necessary.

 -- Finlay



_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >How do I find my Application's directory? (From: Scott Mitchell <email@hidden>)
 >Re: How do I find my Application's directory? (From: Finlay Dobbie <email@hidden>)

  • Prev by Date: Re: How do I find my Application's directory?
  • Next by Date: Re: How do I find my Application's directory?
  • Previous by thread: Re: How do I find my Application's directory?
  • Next by thread: Re: How do I find my Application's directory?
  • Index(es):
    • Date
    • Thread