Is there a way of stopping Windows Live Mail client repeatedly asking whether I want Outlook Express [sic] to compact my messages?
[p.s. please don't suggest that I just switch to a different mail client]
Judging from responses found online, it looks like there is a counter in the registry that counts up each time you close Windows Live Mail or Outlook Express. When the counter gets to 100, it prompts you to compact.
If something causes Windows Live Mail or Outlook Express to load itself into memory then close, the counter is incremented. For example, opening a file with extension .EML while WLM/OE are closed will do it. If another program queries your mail information, the same thing could happen and the counter will increment.
You could either go the trial and error route or the diagnostic route try to fix this.
If you want to be diagnostic, then grab a copy of Process Monitor and run it for a while, then search for anything that's hitting the registry key
If you want to use trial and error route, then it looks like people are blaming any or all of the following: