Announcement Announcement Module
Collapse
No announcement yet.
File upload Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • File upload

    Hi,

    In my application I have an Image object, that contains several String fields and a field that contains the actual content (byte[]).

    I have written an HTML form that will allow me to edit such an Image object. This form is processed by a SimpleFormController. Everything works fine, except that when editing my image I always need to upload the image again. If I don't than the column in the database holding the actual image, is set to null.

    Is there some way I can check if no image was uploaded and in that case only modify the other fields and leave my original image data intact?

    Thanks for any help,

    Arjan Huijzer

  • #2
    There's probably a better way, but why not just grab the existing image (if it's there) and set it again when you're editing the object?

    Comment


    • #3
      Hi,

      That's exactly what I am trying to prevent. I use the web interface to my database from several remote locations, where I do not have the image on the hard drive. This means that if I want to edit an image object I first have to view my image object and save the picture after which I can then change the Image. It's just annoying....

      Thanks for your reaction.

      Arjan

      Comment

      Working...
      X