Possible Duplicate:
Programmatically detect if app is being run on device or simulator
How can I detect whether my app is running on Simulator or on Device via code.
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Keep in mind
UIDeviceprovides you already with information about the device itself.[[UIDevice currentDevice] model]You can also use the following:
TARGET_IPHONE_SIMULATORtells you if you’re in the iPhone simulator.TARGET_OS_IPHONEtells you that you’re working on the iPhone instead of MacOS.and when ONLY interested in the device