I have searched in SO and Google before for this question.
I know that there is a "solution" provided by Erica but when I try it in my iPhone 4S, it simply returns empty string.
NSString* imei = [[UIDevice currentDevice] imei];
Is there anything wrong about this line? I have tried also this line and it succeeds!
NSString* imei = [[UIDevice currentDevice] serialnumber];