What happened to the Messenger Plus! forums on msghelp.net?
Shoutbox » MsgHelp Archive » Skype & Technology » Skype & Live Messenger » Merging chat logs

Merging chat logs
Author: Message:
giken
Full Member
***

Avatar
Windows Live Butterfly

Posts: 404
46 / Male / Flag
Joined: Jan 2003
O.P. Huh?  Merging chat logs
Is there a way to merge two messenger xml chat logs?

I use WLM at home and at work so I have two different chat archives with two xml files for every contact I used to talk to.

I'd like to merge them to get one big chat archive only.

How can I do that?
04-27-2006 08:55 AM
Profile PM Find Quote Report
Funness
Junior Member
**

Avatar

Posts: 58
35 / Male / –
Joined: Jul 2003
RE: Merging chat logs
I assume he put his name when they asked for them.

You may just beable to append one logs to the other. Although this would throw out the time stamps.

This post was edited on 04-27-2006 at 09:37 AM by Funness.
[Image: kingofpants.png]
                                        funness.net
04-27-2006 09:37 AM
Profile PM Web Find Quote Report
CookieRevised
Elite Member
*****

Avatar

Posts: 15517
Reputation: 173
– / Male / Flag
Joined: Jul 2003
Status: Away
RE: Merging chat logs
quote:
Originally posted by giken
Is there a way to merge two messenger xml chat logs?

I use WLM at home and at work so I have two different chat archives with two xml files for every contact I used to talk to.

I'd like to merge them to get one big chat archive only.

How can I do that?

Open up the XML log and study its format...

The structure of XML logs (from both Messenger 7.5 and lower, and WLM 8.0) is something like this:

code:
<?xml version="1.0"?>
<?xml-stylesheet type='text/xsl' href='MessageLog.xsl'?>
<Log LogonName="bebop_007@hotmail.com" FirstSessionID="1" LastSessionID="123">
      <Message Date="..." Time="..." DateTime="..." SessionID="1">
            <From><User LogonName="me@mail.com" FriendlyName="my name"/></From>
            <To><User LogonName="he@mail.com" FriendlyName="his name"/></To>
            <Text Style="...">chat blah blah</Text>
      </Message>
      <Message Date="..." Time="..." DateTime="..." SessionID="2">
            <From><User LogonName="me@mail.com" FriendlyName="my name"/></From>
            <To><User LogonName="he@mail.com" FriendlyName="his name"/></To>
            <Text Style="...">chat blah blah</Text>
      </Message>
      <Message Date="..." Time="..." DateTime="..." SessionID="3">
            <From><User LogonName="me@mail.com" FriendlyName="my name"/></From>
            <To><User LogonName="he@mail.com" FriendlyName="his name"/></To>
            <Text Style="...">chat blah blah</Text>
      </Message>
      ...
      <Message Date="..." Time="..." DateTime="..." SessionID="123">
            <From><User LogonName="me@mail.com" FriendlyName="my name"/></From>
            <To><User LogonName="he@mail.com" FriendlyName="his name"/></To>
            <Text Style="...">merged chat line from other file blah blah</Text>
      </Message>
</Log>


To merge two XML files all you need to do is copy the contents from one file to the other. But only copy the contents between the <log></log> tags, as there can only be 1 of such tag (eg: the chat line with SessionID 123 was copied from another log).

You'll also notice the elements FirstSessionID and LastSessionID in the <log/> tag. If possible, change these accordingly (eg: by means of a specific (non yet existing) merging tool. But it also means that you need to change/update all the SessionID elements in the <Message/> tags. The SessionID, FirstSessionID and LastSessionID elements aren't used (yet) though, so you may also leave them as they are for now. Simply copying everything between the <log></log> tags is sufficient to merge them.


PS: be carefull what to copy from logs of a multi-conversations though.

;)


quote:
Originally posted by Funness
You may just beable to append one logs to the other. Although this would throw out the time stamps.
Unfortunatly not, there can only be 1 tag at the highest level in an XML file*.

Nothing will be thrown out either. Also, timestamps wouldn't be a problem if he never chatted (or logs were saved from contacts contacting him) with both computers at the same time. But he indeed must be "carefull" in his copying so that he respects the order of the timestamps (otherwise the viewed log would jump from one time to the other and back, but nothing will be broken though, it would just be a bit dodgy to read again)...

* and because of that, merging must either be done manually by copy/pasting, or someone must write a program which does this for him. Simply copy-merging whole files together won't work.




quote:
Originally posted by GHOST OF DA AGES
An official tester could help as others dont know about Msg+ live! And u too r an official tester.*GHOST wonders how did he/she become an official tester?
He's not talking about Messenger Plus! in any way.

This post was edited on 04-27-2006 at 02:37 PM by CookieRevised.
.-= A 'frrrrrrrituurrr' for Wacky =-.
04-27-2006 02:06 PM
Profile PM Find Quote Report
giken
Full Member
***

Avatar
Windows Live Butterfly

Posts: 404
46 / Male / Flag
Joined: Jan 2003
O.P. RE: Merging chat logs
Thanks Cookie for the answer :)

I was looking for some kind of automatic tool to do that :)

Maybe a batch file?
04-30-2006 07:44 PM
Profile PM Find Quote Report
CookieRevised
Elite Member
*****

Avatar

Posts: 15517
Reputation: 173
– / Male / Flag
Joined: Jul 2003
Status: Away
RE: Merging chat logs
A batch file mainly automates file handling and stuff. It isn't suited for file contents manipulation. Making a batch file for this is possible, but it would require a very dodgy and way too complicated routine to pull it off.

If you want to do this with something similar like batch files, use/make a VBS script instead.

Note: Any automatic tool which does this either needs to be XML aware (and check for the order of those time/date tags)... or you can make it very straitforward and crude but then you should be very carefully in what files you merge and which not with this tool(/script).

This post was edited on 05-01-2006 at 10:23 AM by CookieRevised.
.-= A 'frrrrrrrituurrr' for Wacky =-.
05-01-2006 10:23 AM
Profile PM Find Quote Report
« Next Oldest Return to Top Next Newest »


Threaded Mode | Linear Mode
View a Printable Version
Send this Thread to a Friend
Subscribe | Add to Favorites
Rate This Thread:

Forum Jump:

Forum Rules:
You cannot post new threads
You cannot post replies
You cannot post attachments
You can edit your posts
HTML is Off
myCode is On
Smilies are On
[img] Code is On