Home > DeveloperSection > Forums > iPad fullNameFromDevice is not retrieved while iPhone fullNameFromDevice is properly retrieved
Manoj Bhatt
Manoj Bhatt

Total Post:154

Posted on    June-05-2013 2:09 AM

 iPhone iPhone 

 1 Reply(s)
 1331  View(s)
Rate this:
Hi Developers,

I have implemented this sample category to get the "fullNameFromDevice" inside my application. Even this example is also not giving me fullNameFromDevice for iPad. There is not any issue to read iPhone device or iPad/iPhone simulator's name using this category.Only issue comes with iPad name.What problem can be?

Suggest me the appropriate solution of this issue.
Your help is a great appreciated. 

Dev Patel

Total Post:26

Posted on    June-17-2013 4:30 AM

Hi Manoj,

Your iPad's name doesn't fit naming patterns suggested by this category.

Look at -(NSString *)fullNameFromDevice:

if (![self deviceNameContainDeviceKind])
    return nil;
Then at

    return [self.name rangeOfString:@"iPhone"].location != NSNotFound
    || [self.name rangeOfString:@"iPod"].location != NSNotFound
    || [self.name rangeOfString:@"iPad"].location != NSNotFound;
You can see that if device's name does not contain "iPhone", "iPod" or "iPad", fullNameFromDevice will return nil.

Don't want to miss updates? Please click the below button!

Follow MindStick