Hi there.
I am running Snow Leopard and running Xcode 4.0.
I am trying to change the color of text in a label, however I can't seem to get it to work.
I read the developer documentation, and when I use the line:
I can't find the proper syntax.
Can someone tell me what I am supposed to do? I know that NSColor is looking for a pointer, but nothing I try seems to work.
Simple for others, perhaps, but I am just starting here.
UPDATE: I am getting closer. This doesn't work, but seems to be on track, if that seems right
The program builds ok, but when I run it and click the button to which this is attached, I crash...
Regards
I am running Snow Leopard and running Xcode 4.0.
I am trying to change the color of text in a label, however I can't seem to get it to work.
I read the developer documentation, and when I use the line:
Code:
[myText setTextColor:<#(NSColor *)#>
I can't find the proper syntax.
Can someone tell me what I am supposed to do? I know that NSColor is looking for a pointer, but nothing I try seems to work.
Simple for others, perhaps, but I am just starting here.
UPDATE: I am getting closer. This doesn't work, but seems to be on track, if that seems right
Code:
[myText setTextColor:(NSColor *) redColor];
The program builds ok, but when I run it and click the button to which this is attached, I crash...
Regards
Last edited: