Photo Gallery Member List Search Calendars FAQ Ticket List Log Out


moving files based on extension with file object

 
Logged in as: Guest
arrSession:exec spGetSession 2,2,54949
 Active Users: There are 0 members and 0 guests.
 Users viewing this topic: none
 

 

 
  
  Printable Version
All Forums >> [Scripting] >> WSH & Client Side VBScript >> moving files based on extension with file object
  Do you like VisualBasicScript.com? Link to us and help spread the word about our forum. Thanks!
Page: [1]
Login
Message << Older Topic   Newer Topic >>
 moving files based on extension with file object - 1/4/2008 4:51:22 AM   
  azimzores

 

Posts: 8
Score: 0
Joined: 12/20/2007
Status: offline
Hey guys i am working on a script to move files from a network location to a local LUN. Currently I have gotten the date diffrence to work but am having trouble to get it to only echo or move files of extension ".log". The netwrok path will have multiple file type in it so just moving the files with extension .log is what i am needing. i have tried acouple diffrent ways and have came up empty handed on only echoing/ moving log files. Thanks for any hep, i am sure its a simple if statement that i can't find the right place for.

~Tony

      
 
 
Post #: 1
 
 RE: moving files based on extension with file object - 1/4/2008 5:04:05 AM   
  ebgreen


Posts: 4971
Score: 31
Joined: 7/12/2005
Status: offline
 

If DDiff <= 15 And UCase(fso.GetExtensionName(File.Name)) = "LOG"  Then

_____________________________

"... when you are good and crazy, oooh, oooh, oooh, the sky is the limit!" - The Tick
Goog places to start:http://www.visualbasicscript.com/m_24727/tm.htm
http://www.visualbasicscript.com/m_47117/tm.htm

(in reply to azimzores)
 
 
Post #: 2
 
 RE: moving files based on extension with file object - 1/4/2008 5:07:10 AM   
  azimzores

 

Posts: 8
Score: 0
Joined: 12/20/2007
Status: offline
THanks alot bro, i knew it was somthing small and stupid. Have a good afternoon and again thanks for the help.

(in reply to ebgreen)
 
 
Post #: 3
 
 
 
  

If you found our site useful please link to us <a href="http://www.visualbasicscript.com">VisualBasicScript.com</a>.
All Forums >> [Scripting] >> WSH & Client Side VBScript >> moving files based on extension with file object Page: [1]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts