PDA

View Full Version : Delete Files


Garry Wilmeth
03-03-2009, 06:06 PM
I am looking for documentation that will help me delete multiple associated files while deleting their respective records with dataassist. For example;

I have a table that includes 6 fields for images. All images are uploaded to the images/bike-images/ folder during the record submission.

If I delete a record from that table, how can I have dataassist/Digital File Pro automatically delete the associated files in the record from the images/bike-images/ directory?

I am looking for the solution while deleting single records as well as deleting multiple records.

Thanks,

Garry

Ray Borduin
03-04-2009, 10:06 AM
You will need to create a recordset to return all of the files tha need to be deleted.

Then use the repeat region server behavior to loop through that recordset and inside it reference the delete file code.

It may require some hand-coding or at least moving some code around by hand after applying.