Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

copy of file

Status
Not open for further replies.

breukelen

Technical User
Oct 31, 2001
54
0
0
NL
I am trying to copy a file by clicking a button :

Private Sub Command4_Click()
FileSystemObject.CopyFile "d:\neurotest.mdb", "d:\my documents\"
End Sub

The above does not work.
Would appreciate some help.

Gunter
 
Try this:

Private Sub Command4_Click()
Dim fs
Set fs = CreateObject("Scripting.FileSystemObject")
fs.CopyFile "d:\neurotest.mdb", "d:\my documents\"
End Sub

HTH
Todd
 
Thank you very much for your help.
Works fine.

best regards ,

Gunter

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top