0
votes

I am trying to figure out how to use NSLengthFormatter with NSTextField. The output should be with local unit but no unit is displayed. I tried to set formatter manually in code and setStringValue:@"22" but it has the same result. What am I doing wrongly?

Screenshot

1

1 Answers

0
votes

A formatter creates a textual representation of an object and the methods of NSLengthFormatter take a double. Try setObjectValue:@22.0.