IOS 开发获取本地图片路径及上传

时间:2024-02-10 03:24:05
【文件属性】:

文件名称:IOS 开发获取本地图片路径及上传

文件大小:37KB

文件格式:PDF

更新时间:2024-02-10 03:24:05

ios ios开发 nsstring

1、获取沙盒路径 NSString *path_document=NSHomeDirectory(); //设置存储文件路径!!!!!!文件路径的名字一定要区分开 NSString *imagePath=[path_document stringByAppendingString:[NSString stringWithFormat:@/Documents/%@%@%@.png,_shopObj.shopPicture,_shopObj.shopColor,self.shopObj.shopName]]; //写入文件 [UIImagePNGRepresentation(im


网友评论