Re: Can't set image in NSImageView
Re: Can't set image in NSImageView
- Subject: Re: Can't set image in NSImageView
- From: email@hidden
- Date: Sat, 7 Feb 2004 17:20:44 EST
In a message dated 02/07/2004 10:02:12, email@hidden writes:
>
try something like this:
>
>
NSString *myImageName = @"onstate.png";
>
NSImage *myImage = [NSImage imageNamed: myImageName];
>
[statusImage setImage:myImage];
>
>
See the description of "imageNamed" in the NSImage docs.
>
>
-lance
>
_______________________________________________
Thanks for the reply Lance but I think:
NSImage *myImage;
myImage = [NSImage imageNamed:@"onstate"];
[statusImage setImage:myImage]; // show On Icon
is a more politically correct.
_______________________________________________
Dale
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.