Dear All,
i am new on programming. I am making one script by using powershell.
I have many computer log files in a folder, the following are some sample files in the folder
server_authlog_computername1_20130602.log
server_authlog_computername11_20130603.log
server_authlog_computername2_20130601.log
server_authlog_computername1_20130530.log
Remarks:-
All the log files have the same string from the front and have two underscore before the computername(and computername string length of each log file is not the same)
I will need the script to get the characters string(computername) from the filename and create directory from string, and move the right computername files to the same computername folder.
Could anyone advise or suggest me on this?
Thanks and Regards,
Edward