I have a powershell script that loops through a folder and takes the last line of about 12 log files. The last line of each file is basically similar to the one below however the end where it says X were rejected might be different.
[Wed Oct 02 08:41:53 EDT 2013]Planning Outline data store load process finished. 2 data records were read, 2 data records were processed, 2 were accepted for loading (verify actual load with Essbase log files), 0 were rejected.
What I am looking for is some way in powershell to somehow seperate only the last part where it says X were rejected. and either store it to a variable or write it to a text file.