Set selected image of ImageField server side
I have a custom widget where users can select an image and add to a list object. I need a way to set the selected image of a ImageField within server side event. How it works is that I have a table where it lists all the selected images. For each item there's buttons Edit and Delete. When they click Edit it will fire its onclick event server side and will make the ImageField visible. Within this onclick event I want to set the selected image of the ImageField. Is there a way to do this?