3.0.5

Empty XML nodes in Firefox

I'm having issues in Firefox when the data is loaded via a data island.

If there is a node with an empty body (ex: <name></name> ) I get:

Error: uncaught exception: [Exception... "Component returned failure code: 0x8007000e (NS_ERROR_OUT_OF_MEMORY) [nsIDOMNSHTMLDocument.write]" nsresult: "0x8007000e (NS_ERROR_OUT_OF_MEMORY)" location: "JS frame :: file:.../ActiveWidgets/examples/grid/xml%20-%20data%20island.htm :: <TOP_LEVEL> :: line 203" data: no]

If the node has no body (ex: </name>) then the grid will render, but ithe data stops at the </name> node.

If the node has spaces for the body (ex: <name> </name>) then the grid works correctly, but with some visual issues.

Is there any workarround/fix for this issue?

I'm pretty sure I'm doing things correctly because I see this issue in the data island example when I blank out a node.
Mike Graessle
January 6,
Had the same problem.

The workarround is to place a space in every empty node ;-)

The workarround for the visual problem is to replace every empty string or string with spaces with a &nbsp;

I did this by creating a Format Object:

Active.Formats.MyString = Active.System.Format.subclass();
Active.Formats.MyString.create = function(){
var obj = this.prototype;

obj.dataToValue = function(data){
return data.toUpperCase();
};

obj.dataToText = function(data){
if ( isBlank(data) ) { return '&nbsp;'; }
return data;
};
};

Active.Formats.MyString.create();

and the assigned it to the xml tabel object:

var string = new Active.Formats.MyString;

var formats=[string,string,string];
table.setFormats(formats);

But this is just a workarround. The bug should be fixed in the grid.
Dietrich
February 9,

This topic is archived.

See also:


Back to support forum