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 wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Re: faq705-3579

Status
Not open for further replies.

cykopat

Technical User
Jun 4, 2003
56
US
I was wondering if someone could quickly tell me how to modify this to also include the TIME checking. Thanks very much..
faq705-3579

I tried to find the authors email to avail..
 
Use the "Send a comment" link at the bottom of the FAQ to contact the author regarding it.

John
 
thanks.. I figured out my own way to do the same thing..Maybe this can help someone also..



Update " PathSource Here ", "PathTarget Here"


Function Update(sSource, sTarget)
Dim oFSO
Dim oSource

Set oFSO = WScript.CreateObject("Scripting.FileSystemObject")

If oFSO.FileExists(sSource) Then
Set oSource = oFSO.GetFile(sSource)
If Not oFSO.FileExists(sTarget) Then
oSource.Copy sTarget, True
ElseIf oSource.DateLastModified > oFSO.GetFile(sTarget).DateLastModified Then
oSource.Copy sTarget, True
End If
Else
MsgBox "Source file does not exist!"
End If
End Function
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top