Save image in asset catalog on runtime
Asked Answered
D

1

7

I have to download new images from backend in background process and i need to save them for use later in the app.

In the other way, the original app images are in the asset catalog and when i add the new ones all images must accessed from the asset catalog.

I try to add images to directory's app but when i have to load any image the app do not know to discriminate between images in asset catalog and other, and i thing this is not the best solution for this

I do not know how add images to asset catalog on runtime or if i have to try other way to support this.

Any help i been so grateful

Many thanks!

Detinue answered 25/7, 2014 at 6:15 Comment(0)
U
12

Asset catalog is a resource file/folder, that means this is placed inside your bundle.

All files inside your bundle means it is not writable. The files inside bundle has only read permissions.

You have to store in any one of the sandboxed folders (Documents, Library and temp)

Undecided answered 25/7, 2014 at 6:20 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.