I have following text after reading a file:
06/16/2011 04:01:05 AM : Process Start
06/16/2011 04:01:05 AM : Creating File
06/16/2011 04:01:05 AM : Opening File
06/16/2011 04:01:05 AM : Writing Text
06/16/2011 04:01:05 AM : Closing File
06/16/2011 04:01:05 AM : Sending File in email
06/16/2011 04:01:05 AM : Process End
I want to remove date and time in the beginning of each line like this:
Process Start
Creating File
Opening File
Writing Text
Closing File
Sending File in email
Process End
How can we do this with string matching technique ?
Thanks
One way to do this would be the following: (assuming the prefix is always the same length)
First you
explodethe input into a variable by splitting it on every new line, and then for each line you remove the first 25 characters to create a new output.http://codepad.org/ewuecNuU