Oh, right. I didn't think of that. Thanks for the correction and clarification.
F.
On Sat, Apr 12, 2008 at 6:46 PM, Ken Thomases <[EMAIL PROTECTED]> wrote:
>
> You're grabbing all defaults from all domains with the above, and promoting
> them all into the NSArgumentDomain below, changing their p
On Apr 12, 2008, at 8:13 AM, [EMAIL PROTECTED] wrote:
Thanks Ken!
You're welcome.
int main(int argc, char *argv[])
{
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
NSMutableDictionary* myValues = [NSMutableDictionary
dictionaryWithCapacity:1];
[myValues setDic
Thanks Ken! That worked perfectly. Still curious why tweaking the
argv[] array didn't, though. I did use a preceding dash for the key,
and so it should have been the exact same thing as the code below, no?
Anyway, here is a working example for anyone interested. Thanks again.
int main(int argc, ch
On Apr 12, 2008, at 5:45 AM, Ken Thomases wrote:
[[NSUserDefaults sharedUserDefaults]
removeVolatileDomainForName:NSArgumentDomain];
[[NSUserDefaults sharedUserDefaults] setVolatileDomain:myValues
forName:NSArgumentDomain];
Oops. s/sharedUserDefaults/standardUserDefaults/g
-Ken
_
On Apr 12, 2008, at 5:08 AM, [EMAIL PROTECTED] wrote:
Couldn't you just store your custom args in a global and access
them later when you need
them?
My goal is to replace an existing setting in the NSArgumentDomain, so
storing the setting in the application domain isn't good enough as
NSArgum
> If you're using NSProccessInfo to get the args, then changing them at runtime
> won't work
> as far as I know. The args are stored before main is even called. I don't
> think passing
> args to NSApplicationMain has any kind of effect.
No, I'm not getting the args from NSProcessInfo but from
BTW, not sure why you're trying to feed in custom args but if it's for
testing purposes you can tell Xcode what args to pass by getting info
on your program under Executables and put the launch arguments in there.
On Apr 11, 2008, at 8:01 PM, [EMAIL PROTECTED] wrote:
'm trying to add some
If you're using NSProccessInfo to get the args, then changing them at
runtime won't work as far as I know. The args are stored before main
is even called. I don't think passing args to NSApplicationMain has
any kind of effect.
Couldn't you just store your custom args in a global and acces
Hi,
I'm trying to add some launch arguments to my executable by modifying
the arguments passed to main.m, but find that the new arguments are
completely ignored. No matter what I pass to NSApplicationMain the
executable launches with the same old default argsv[]. Is this not the
right approach? Sh