Function Trouve_Fich(Fichier$) As Boolean
Trouve_Fich = Dir(Fichier) <> ""
End Function
Sub Test_Archivage()
Dim vnomfichier As String
Dim Vchemin As String
Dim strdate As String
Dim mois As String
Dim annee As String
Dim vnomfichierbase As String
Dim test As String
strdate = Format(CDate(Date), "mm") ' & Format(Time, "h-mm-ss"))
annee = Format(CDate(Date), "yy")
vnomfichier = ("Calcul")
mois = strdate - 1
vnomfichierbase = ("Calcul Mois en Cours")
test = "[URL="file://\\Test\2010\"]\\Test\2010\[/URL]" + mois + " " + vnomfichier + " " + annee + ".xls"
'If Dir(test) = False Then
If Trouve_Fich(test) = True Then
'juste pour le test modifier ensuite
MsgBox "trouvé alors je quitte"
Exit Sub
Else
'juste pour le test modifier ensuite
MsgBox "Archiver_le_mois_precedent"
End If
End Sub