3.2.0

XML Dataset works only with firefox

This is the html file:

<html>
<head>
<title>Relux bestueckung</title>
<style> body, html {margin:0px; padding: 0px; overflow: hidden;} </style>

<!-- ActiveWidgets stylesheet and scripts -->
<link href="./css/grid.css" rel="stylesheet" type="text/css" ></link>
<script src="./lib/grid.js"></script>

<!-- grid format -->
<style>
.active-controls-grid {height: 100%; font: menu;}

.active-column-0 {width: 80px;}
.active-column-1 {width: 200px;}
.active-column-2 {text-align: left;}
.active-column-3 {text-align: left;}
.active-column-4 {text-align: left;}
.active-column-5 {text-align: left;}

.active-grid-column {border-right: 1px solid threedshadow;}
.active-grid-row {border-bottom: 1px solid threedlightshadow;}
</style>
</head>
<body>
<script>

// create data formats
var string = new Active.Formats.String;
var number1 = new Active.Formats.Number;
var number2 = new Active.Formats.Number;
var date = new Active.Formats.Date;

// define formatting rule for text output
number1.setTextFormat("#,###.##");
number2.setTextFormat("");

date.setTextFormat("dd mmm yy");
date.setDataFormat("ISO8061");

// create ActiveWidgets data model - XML-based table
var table = new Active.XML.Table;

// provide data URL
table.setURL("./xml/relux.xml");

// set rows XPath
table.setRows("//bestueckung/*");

// set columns XPath
table.setColumns(["ArtikelNr", "AnzKombi", "AnzKombi",
"AnzLampen", "UGruppe1", "UGruppe2","MinWatt",
"MaxWatt","Hersteller","LVK_Datei",
"Bild_Datei","bLVKDatei","Geo3d"]);

// set column formatting
table.setFormats([string, string, string,
number1, number1, number1,number1,string,
string, string,string,string]);

// start asyncronous data retrieval
table.request();

// define column labels
var columns = ["ArtikelNr", "AnzKombi", "AnzKombi",
"AnzLampen", "UGruppe1", "UGruppe2","MinWatt",
"MaxWatt","Hersteller","LVK_Datei",
"Bild_Datei","bLVKDatei","Geo3d"];

// create ActiveWidgets Grid javascript object
var obj = new Active.Controls.Grid;

// provide column labels
obj.setColumnProperty("texts", columns);

// provide external model as a grid data source
obj.setDataModel(table);

// allow multiple selection
obj.setSelectionProperty("multiple", true);

// write grid html to the page
document.write(obj);

</script>
</body>
</html>

and this is a portion of the xml file:

<?xml version="1.0"?>
<relux xmlns="ReluxDB">
<diffgr:diffgram xmlns:msdata="urn:schemas-microsoft-com:xml-msdata" xmlns:diffgr="urn:schemas-microsoft-com:xml-diffgram-v1">
<bestueckung xmlns="">
<item>
<ArtikelNr>37118</ArtikelNr>
<AnzKombi></AnzKombi>
<ArtNrKombi></ArtNrKombi>
<AnzLampen>1</AnzLampen>
<UGruppe1>5</UGruppe1>

<UGruppe2>600</UGruppe2>
<MinWatt></MinWatt>
<MaxWatt>18</MaxWatt>
<Hersteller></Hersteller>
<LVK_Datei></LVK_Datei>
<Bild_Datei></Bild_Datei>
<bLVKDatei>0</bLVKDatei>

<Geo3d></Geo3d>
</item>
<item>
<ArtikelNr>37118-cri</ArtikelNr>
<AnzKombi></AnzKombi>
<ArtNrKombi></ArtNrKombi>
<AnzLampen>1</AnzLampen>
<UGruppe1>5</UGruppe1>

<UGruppe2>600</UGruppe2>
<MinWatt></MinWatt>
<MaxWatt>18</MaxWatt>
<Hersteller></Hersteller>
<LVK_Datei></LVK_Datei>
<Bild_Datei></Bild_Datei>
<bLVKDatei>0</bLVKDatei>

<Geo3d></Geo3d>
</item>
<item>
<ArtikelNr>37118/DL</ArtikelNr>
<AnzKombi></AnzKombi>
<ArtNrKombi></ArtNrKombi>
<AnzLampen>1</AnzLampen>
<UGruppe1>5</UGruppe1>

<UGruppe2>600</UGruppe2>
<MinWatt></MinWatt>
<MaxWatt>18</MaxWatt>
<Hersteller></Hersteller>
<LVK_Datei></LVK_Datei>
<Bild_Datei></Bild_Datei>
<bLVKDatei>0</bLVKDatei>

<Geo3d></Geo3d>
</item>
<item>
<ArtikelNr>37118/DL/SA</ArtikelNr>
<AnzKombi></AnzKombi>
<ArtNrKombi></ArtNrKombi>
<AnzLampen>1</AnzLampen>
<UGruppe1>5</UGruppe1>

<UGruppe2>700</UGruppe2>
<MinWatt></MinWatt>
<MaxWatt>18</MaxWatt>
<Hersteller></Hersteller>
<LVK_Datei></LVK_Datei>
<Bild_Datei></Bild_Datei>
<bLVKDatei>0</bLVKDatei>

<Geo3d></Geo3d>
</item>

It's works perfectly under firefox 1.5 but it shows "No data found" under explorer, why???
Daniele
February 18,
Solved, in the xml I have to pu the string msdata:rowOrder="0" in the item tag.
Daniele
February 18,
No it doesn't work, is it possible that it doesn't works because in the xml there are others groups? But with firefox it works greatly.
Daniele
February 18,
It doesn't work because there are others group, how can i solve this problem?
Daniele
February 18,

This topic is archived.

See also:


Back to support forum