We're not a code-writing service, so I'll assume you're asking for a general approach you can use to start building a program. So here goes:
I'd suggest you create a hash, and when you see a movie start time, add it to the hash using the video title as the hash key. Then when you see a stopped tag, you can look up the start time from the hash and print the video title and duration and remove it from the hash.
There would be two special cases you'll want to handle: (1) You may receive a Stopped message without a Played record. Just print a warning when this occurs. (You'll be able to detect it because the video isn't in the hash.) The other special case is when you reach the end of your file, and there are some videos that haven't received their Stopped message yet. Just scan through the hash and print appropriate messages as req'd.
...roboticusIn reply to Re: report generation
by roboticus
in thread report generation
by rgb
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |