FileSystemObjects Move command

  • Thread starter Thread starter STom
  • Start date Start date
S

STom

If I am moving a file with the FileSystemObjects move command, will the code
not move to the next process until the file has completely finished being
moved? I just want to make sure that the file is moved before I continue on.

Thanks.

STom
 
STom said:
If I am moving a file with the FileSystemObjects move command, will the code
not move to the next process until the file has completely finished being
moved? I just want to make sure that the file is moved before I continue
on.

If you are using an instance of the FileInfo object, it is synchronous,
which means that it does not release until the operation has completed. The
file will be moved before the next line of your code is executed.

R.
 
STom said:
If I am moving a file with the FileSystemObjects move command

If you /really/ mean the FSO ...

Why?

The File manipulation classes provided by the framework are
*far* superior, don't need [yet] another DLL deploying with
your application and don't get disabled by paranoid Server
Administrators.

System.IO.File.Move( "from", "to" )

HTH,
Phill W.
 
Thanks guys for pointing this out!

STom
Phill. W said:
STom said:
If I am moving a file with the FileSystemObjects move command

If you /really/ mean the FSO ...

Why?

The File manipulation classes provided by the framework are
*far* superior, don't need [yet] another DLL deploying with
your application and don't get disabled by paranoid Server
Administrators.

System.IO.File.Move( "from", "to" )

HTH,
Phill W.
 
Back
Top