function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion

Add Image to Static Resources using Apex code

Is it possible to add an image to static resources using apex code?


On a detail page I want to click a button that says upload image and store that image in static resources rather than in attachments on the individual record.


Is the possible and if so do you have any sample code?


Not in apex, no. Probably over metadata API, but that would probably add more problems than it solves.

Is this still the case?