在终端里输入:
sudo ln -s /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/codesign_allocate /usr/bin
UIImageWriteToSavedPhotosAlbum(image, self, nil, nil);
sudo ln -s /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/codesign_allocate /usr/bin
并回车,则可解决
在iphone程序中实现截屏的一种方法:
//导入头文件
#import <QuartzCore/QuartzCore.h>
//将整个self.view大小的图层内容创建一张图片image
UIImageWriteToSavedPhotosAlbum(image, self, nil, nil);