thunderbird adding a view column

Posted on 2008-10-05
Last Modified: 2012-06-21
I wanted to know how to add a new column to messages view, like we do in Microsoft outlook. In outlook, we can customize the current view as View->Arrange By->Current View->Customize current view... and we can select the fields to add to view. I understand I need to write a chrome to do that, but don't know which file I should extend?
Question by:Ajay-Singh
  • 5
  • 3
LVL 30

Expert Comment

ID: 22649083
Before you start creating something you might not need, have you checked (when in the mailbox folder of your choice) in the View->Sort By to see if your Customized view has already been set as an option?
LVL 30

Expert Comment

ID: 22649375
According to
you can install this add-on and it may do what you desire.
LVL 23

Author Comment

ID: 22651589
I tried that. It doesn't do what I need. It just changes the message display pane to show extra headers.

May be I was not clear earlier...
I want to add the custom headers (outside the predefined ones) as one of the columns on the message view pane and I want to sort by that too...
LVL 30

Expert Comment

ID: 22653514
I understand.  I cannot help showing the custom headers, because  I don't know how to.

Sorry if I wasted your time. Perhaps someone else can help you on this one.

Maybe this page will help,
What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

LVL 23

Author Comment

ID: 22659847

The links you have given is very informative. I have written the overylay and js. Unfortunately, its not working. Can you check and let me know if everything is ok here?
xul file:

<?xml version="1.0"?>

<overlay xmlns:html=""


	<script src="a.js"/>



	<stringbundle id="bundle_fpse" src="chrome://global/locale/"/>



	<tree id="threadTree">

		<treecols id="threadCols">

			<splitter class="tree-splitter"/>

			<treecol id="colReplyTo" persist="hidden ordinal width"

				currentView="unthreaded" flex="2" label="Reply-To"

				tooltiptext="Click to sort by the Reply-To header"/>





var columnHandler = {

   getCellText:         function(row, col) {

      //get the message's header so that we can extract the reply to field

      var key = gDBView.getKeyAt(row);

      var hdr = gDBView.db.GetMsgHdrForKey(key);


      return hdr.getStringProperty("replyTo");


   getSortStringForRow: function(hdr) {return hdr.getStringProperty("replyTo");},

   isString:            function() {return true;},

   getCellProperties:   function(row, col, props){},

   getRowProperties:    function(row, props){},

   getImageSrc:         function(row, col) {return null;},

   getSortLongForRow:   function(hdr) {return 0;}


//gDBView.addColumnHandler("colReplyTo", columnHandler);

window.addEventListener("load", doOnceLoaded, false);


function doOnceLoaded() {

  var ObserverService = Components.classes[";1"].getService(Components.interfaces.nsIObserverService);

  ObserverService.addObserver(CreateDbObserver, "MsgCreateDBView", false);


var CreateDbObserver = {

  // Components.interfaces.nsIObserver

  observe: function(aMsgFolder, aTopic, aData)





function addCustomColumnHandler() {

   gDBView.addColumnHandler("colReplyTo", columnHandler);


Open in new window

LVL 30

Accepted Solution

mtz1of4 earned 500 total points
ID: 22683184
Sorry, Ajay-Singh,

I don't know how to read code.  Perhaps these guys over at this forum may be of assistance.
Either or
LVL 23

Author Comment

ID: 22718966
Sure, I was wondering if somebody else from this forum can help me out on this?

Expert Comment

ID: 25508601
Sorry I'm a latecomer on this, but I encountered this thread while trying to solve the same problem.   If I understand the problem correctly, I have now found a much simpler solution.  My Thunderbird is v2.0, and there is a button on the far right of the column headings whose tool tip is "Click to select columns to display."
LVL 30

Expert Comment

ID: 25517592
Sorry CharlieL, he wanted to create a Custom Header and sort by it, not one of the predefined one.

I want to add the custom headers (outside the predefined ones) as one of the columns on the message view pane and I want to sort by that too...

Featured Post

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

We have come a long way with backup and data protection — from backing up to floppies, external drives, CDs, Blu-ray, flash drives, SSD drives, and now to the cloud.
Use of TCL script on Cisco devices:  - create file and merge it with running configuration to apply configuration changes
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor ( If you're interested in additional methods for monitoring bandwidt…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

747 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now