I am facing the problem, that I can't convert an string or an int to an UInt16. This is my current code: (UInt16)[[defaults stringForKey:@"port"] intValue]
[[defaults stringForKey:@"port"] intValue]
is 8080
and (UInt16)[[defaults stringForKey:@"port"] intValue]
becomes 51075
which is wrong. Does anyone know to do this?
Thanks for your help!