Files & Paths & Filecopy command

TeneQuodBene

New member
Local time
Today, 18:20
Joined
Nov 20, 2003
Messages
9
Hello,

I'm not so familiar with VBA but what I'm trying to do here is... :
1) I've got a database with used cars.
2) Every car has a picture (linked -> not embedded) wich is stored in a field.
3) When I select a picture and automatic filecopy is done to a subdirectory where I keep my webimages
4) When I delete a file (Kill command), the file in the image directory is deleted...

So far so good

My problem :
1) When there are several records which use the same file, the file should not be deleted...
How can I accomplish this? Maybe run a query on exit of the form which copies all the files again...??? Please help me...

I hope I made my problem clear
 
Do you have a table storing the links to the pictures?

If so, just count the number of links in the table before you delete the file, like:

If dcount(.......) <= 1 then
kill......
etc

Fuga.
 

Users who are viewing this thread

Back
Top Bottom