I am wondering how my iPhone app can take a screen shot of a specific UIView as a UIImage.
UIView
UIImage
I tried this code but all I get is a blank image
-(UIImage *)convertViewToImage { UIGraphicsBeginImageContext(self.bounds.size); [self drawViewHierarchyInRect:self.bounds afterScreenUpdates:YES]; UIImage *image = UIGraphicsGetImageFromCurrentImageContext(); UIGraphicsEndImageContext(); return image; }