On 25 Oct 2009, at 20:13, Dave DeLong wrote:


On Oct 25, 2009, at 2:08 PM, Ian Piper wrote:

It also has a method called convertCToF that ... returns the converted temperature, also as a float.

NSNumber *newTemperatureInF = [testConverter convertCToF]; // This is where I get the error "Incompatible types in initialization"

An NSNumber (an object) is not the same thing as a float (a primitive). The latter is a raw numerical value, and the former is an object that encapsulates a numerical value.

*Slaps forehead*. Thanks very much.


Ian.
--
_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to