The Deep End

go to! email!

Tuesday, August 23, 2005

Populating the Messagepane in Thunderbird??

You know, the message preview pane--how does that get populated with the body of whatever selected message?? How do you get the body of a message in general? Setting up a stream and then reading the body out of the stream won't work for IMAP messages, because you have to download them first. How would one go about accomplishing that?


  • At Thursday, August 25, 2005 4:16:00 PM, Anonymous Rory Parle said…

    I've been trying to find this out for several weeks. I've tried every forum I can find, two Thunderbird newsgroups, reading the source code, and searches of all the Mozilla development sites. I think the only thing left to do is to contact a developer directly and ask for (at least) some hints. If you do find out how to do this I'd love to hear how.

  • At Tuesday, September 06, 2005 7:07:00 AM, Anonymous Rory Parle said…

    I contacted Scott MacGregor about this, and he pointed me to the function LoadMessageByUri() defined in commandglue.js. I hope this helps you. It helped me.

  • At Wednesday, February 15, 2006 6:54:00 AM, Anonymous Anonymous said…

    var messageService = messenger.messageServiceFromURI(uri);
    var messageStream = Components.classes[";1"].createInstance().QueryInterface(Components.interfaces.nsIInputStream);
    var inputStream = Components.classes[";1"].createInstance().QueryInterface(Components.interfaces.nsIScriptableInputStream);
    try {
    messageService.streamMessage(uri, messageStream, msgWindow, null, false, null);
    } catch (ex) {
    return null;

    var body = "";
    while (inputStream.available()) {
    body = body +;



  • At Wednesday, April 12, 2006 5:29:00 PM, Anonymous Anonymous said…

    How will I get the uri ? Can somebody please post the source code.


Post a Comment

<< Home