I have a function that finds out if one of the databases exists, then imports the content of it, processes them and deletes it.
Ususaly all of the 12 databases are present, and the function looks up for them, one after another, processes the content and then deletes the file.
My question is, is it possible to name the paths in brackets, and then leave the function looks up for the databases one after another,
imports the content from each database and then delete it?
The function i use it now is as follows:
Public Function Collect()
‘ first collect from History
If Dir(DtHistory, vbNormal) “” Then
Call FromDepot(DHistory)
ProcessTables
Kill (DHistory)
End If
If Dir(DSo, vbNormal) “” Then
Call FromDepot(DSo)
ProcessTables
Kill (DSo)
End If
If Dir(DVa, vbNormal) “” Then
Call FromDepot(DVa)
ProcessTables
Kill (DVa)
End If
etc etc