Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
How to move files from the code
Hi ,
does anyone know how to move all the file from one folder to another from the code ? For example : move *.* from C:\A to C:\B thanks ana |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
How to move files from the code
try
Sub movefile() OldName = "C:\Al\yourfilename.xls" NewName = "C:\B\yourfilename.xls" Name OldName As NewName End Sub -- Don Guillett SalesAid Software "Ana" wrote in message ... Hi , does anyone know how to move all the file from one folder to another from the code ? For example : move *.* from C:\A to C:\B thanks ana |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
How to move files from the code
Hi Ana,
Try this routine posted by Dana deLouis: Sub FilesMoveBetweenFolders() Const FromFolder As String = "D:\Assets\*.*" Const ToFolder As String = "D:\Closing\" On Error Resume Next With CreateObject("Scripting.FileSystemObject") .CopyFile FromFolder, ToFolder, True .DeleteFile FromFolder, True End With End Sub --- Regards Norman "Ana" wrote in message ... Hi , does anyone know how to move all the file from one folder to another from the code ? For example : move *.* from C:\A to C:\B thanks ana |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
How to move files from the code
Hi Ana,
Try this name "C:\MyDir" as "C:\NewDir" -- HTH Bob Phillips ... looking out across Poole Harbour to the Purbecks (remove nothere from the email address if mailing direct) "Ana" wrote in message ... Hi , does anyone know how to move all the file from one folder to another from the code ? For example : move *.* from C:\A to C:\B thanks ana |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
VBA Code - Find & Move | Excel Discussion (Misc queries) | |||
VBA Code - Find & Move | Excel Discussion (Misc queries) | |||
Pivot Table VBA code to move a row | Excel Discussion (Misc queries) | |||
vba code to find ssn and move two columns | Excel Programming | |||
code to move certain rows to another sheet | Excel Programming |