Re: Update NSTextField programatically while cursor is in it
Re: Update NSTextField programatically while cursor is in it
- Subject: Re: Update NSTextField programatically while cursor is in it
- From: Randy Bradley <email@hidden>
- Date: Fri, 9 Jun 2006 16:52:03 -0500
The NSTextField is hidden by the field editor. Update the field editor
instead. email@hidden
Thanks Matt,
So, this is what I ended up with and it seems to work:
NSWindow *weightWindow =
[[[self windowControllers] objectAtIndex:0] window];
if ([[weightWindow fieldEditor:YES forObject:nil] delegate] ==
animalField)
[weightWindow endEditingFor:animalField];
[animalField setStringValue:[tmpAnimal number]];
If anyone sees any problems or has a better solution, please let me
know.
_______________________________________________
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