Error warnings when used in HTA

44 views
Skip to first unread message

djBo

unread,
May 23, 2006, 1:50:16 PM5/23/06
to DOM Menu Library
Hi,

I'm using domMenu with much success in an HTA application i'm working
on.
HTA is nothing more than serving your pages as application/hta.
However, HTA allows system access without asking the user. As I'm
developing a secured legal application this comes in pretty handy :)

Now the menu works great on most pages except at least one... our
editor page containing TinyMCE.
The page has a single link back to the homepage on the domMenu.
When I click that, I get the following error message from IE6:

A runtime error has occurred.
Want to debug?
Line: 973
Error: Object doesn't support this property or method

Using the VSDebugger I got to the line:
el[clearElementProps[c]] = null;

Obviously I'm no javascript guru, so I started of with a search for
clearElementProps whose first link came to a post by Richard Cornford
about some memory leak and exactly THIS line...

I hope someone can shed some light on what is going on...
Currently I'm blaming that HTA for not doing the right thing, as
serving the pages as text/html is working flawless. Leaves me with our
application asking for system access though...

Cheers and thanks in advance for any reply :)
Rory

Dan Allen

unread,
Oct 23, 2006, 5:53:14 AM10/23/06
to dom-...@googlegroups.com
Ah, okay. Basically, the event handlers are being cleared out of the
DOM when the page unloads to prevent a memory leak in IE. However,
the code doesn't handle the case when the DOM object doesn't support
the operation. It is harmless, and should be silenced.

I will add the following fix to the next release of domMenu.js. Find
this line and surround it with a try/catch.

try {


el[clearElementProps[c]] = null;

} catch (e) {
// oh well, we tried
}


/dan


--
Daniel Allen
Registered Linux User #231597

Mojavelinux.com: Open Source Advocacy
http://www.mojavelinux.com

While I make a strong effort to keep up with my email on a daily basis,
life and work come first and, at times, keep me away from my mail for a
while. If you contact me and then don't hear back for more than a week,
it is very likely that I am excessively backlogged or the message was
caught in the filters. Please don't hesitate to resend a message if
you feel that it did not reach my attention.

Reply all
Reply to author
Forward
0 new messages