Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

problem with addeventlistener in thunderbird

10 views
Skip to first unread message

Steff81

unread,
Dec 18, 2009, 6:29:01 AM12/18/09
to
hi
i'm using the function

<script>
window.addEventListener("unload", autoExportOnClose, false);
</script>

in my xul overlay for thunderbird to start my automatic export from
lightning.
but it doesn't work with failure...

Fehler: [Exception... "'[JavaScript Error: "autoExportPrefs is not
defined" {file: "chrome://autoexport/content/autoExport.js" line:
116}]' when calling method:
[calIOperationListener::onOperationComplete]" nsresult: "0x80570021
(NS_ERROR_XPC_JAVASCRIPT_ERROR_WITH_DETAILS)" location: "JS frame ::
file:///D:/11%20AppData/Thunderbird/Steffen/extensions/%7Be2fda1a4-762b-4020-b5ad-a41df1933103%7D/modules/calProviderUtils.jsm
:: cPB_notifyOperationComplete :: line 600" data: yes]

line 116 ...
> if (autoExportPrefs.getBoolPref(mode + ".exportFormat.ics"))

this failure occurs although there is the global definition...

> var autoExportPrefs = Components.classes["@mozilla.org/preferences-service;1"].getService(Components.interfaces.nsIPrefService).getBranch("ae.prefid.");

this failure doesn't occur if i start the export with a button during
thunderbird is running with the same code.
and this is new with thunderbird 3

has anyone an idea?

thanks in advance
regards
steff

0 new messages