Application.FileSearch 2007 Reference

J

Justin

I have the following code that works fine with Acess 2002 SP2. I run the
same code useing Acess 2007 SP2 I get Run-time error 2455 "You entered an
expression that hase an invalid reference to the property FileSearch". Both
system set-ups have the same set of references.

With Application.FileSearch
.NewSearch
.LookIn = sPath
.FileName = sFile
If .Execute() > 0 Then
If MsgBox("Delete existing file " & sPath & sFile & "?",
vbYesNo, "Dupilcate File Name") = vbYes Then
Kill (sPath & sFile)
Else
MsgBox "Delete or rename file " & sPath & sFile & ".",
vbOKOnly, "Dupilcate File Name"
Exit Sub
End If
End If
End With
 
J

Jack Leach

The Application.Filesearch functionality was apparently removed from the 2007
suite. If you google Application.Filesearch 2007 you should be able to find
a few alternatives.

hth

--
Jack Leach
www.tristatemachine.com

"I haven''t failed, I''ve found ten thousand ways that don''t work."
-Thomas Edison (1847-1931)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top