iPhone - Using a define [closed]
I am a newbie on iPhone development.
I have declared开发者_如何转开发 a variable on my .m file like this
#define myFloat 60.0f
Now when I try to use this variable like
CGRect myFrame = CGRectMake(0.0f, 0.0f, myFloat, myFloat);
it says myFloat is undeclared!
How do I do that?
thanks.
Try putting the #define in the .h file.
精彩评论