• 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: Launching Application with arguments
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Launching Application with arguments


  • Subject: Re: Launching Application with arguments
  • From: Ondra Cada <email@hidden>
  • Date: Mon, 19 Nov 2001 19:05:05 +0100

Yves,

>>>>>> Yves Peneveyre (YP) wrote at Mon, 19 Nov 2001 15:27:45 +0100:
YP> Now, I'd like to retrieve the arguments in the launched application.
YP> Ok, I can modifiy the "main(...)" function to get the arguments,
YP> but I'd like to know if there is an other way to do this......

I guess there would be other ways, but I somehow got used to use arguments
of general pattern "-<name> <value>".

Such arguments can be read anywhere using the NSUserDefaults API.

You can get the args directly through NSProcessInfo's arguments method, but
I consider the above to be *much* more flexible and convenient.
---
Ondra Cada
OCSoftware: email@hidden http://www.ocs.cz
2K Development: email@hidden http://www.2kdevelopment.cz
private email@hidden http://www.ocs.cz/oc


References: 
 >Launching Application with arguments (From: "Yves Peneveyre" <email@hidden>)

  • Prev by Date: why is numbersOfRowInTableView called before awakeFromNib?
  • Next by Date: Mutability
  • Previous by thread: Launching Application with arguments
  • Next by thread: Re: Launching Application with arguments
  • Index(es):
    • Date
    • Thread