:: Forum >> Version 2 >>

edit.htm refresh consistently crashes IE


My version of the edit.htm keeps crashing on IE everytime i refresh the page on version 2. I am still evaluating the production and would like to start using it soon.

--------------------------------------------------
<html>
<head>
<script src="../../runtime/lib/aw.js"></script>
<link href="../../runtime/styles/xp/aw.css" rel="stylesheet"></link>
<style> body, html {margin:0px; padding: 0px; overflow: hidden;} </style>

<!-- grid format -->
<style>
.aw-grid-control {height: 100%; width: 100%; margin: 0px; border: none; font: menu;}
.aw-row-selector {text-align: center}

.aw-column-0 {width: 80px;}
.aw-column-1 {width: 200px;}
.aw-column-2 {text-align: right;}
.aw-column-3 {text-align: right;}
.aw-column-4 {text-align: right;}

.aw-grid-cell {border-right: 1px solid threedlightshadow;}
.aw-grid-row {border-bottom: 1px solid threedlightshadow;}
</style>

</head>
<body>
<script>

var obj = new AW.UI.Grid;
obj.setCellText(function(i, j){return j + "." + i});
obj.setHeaderText("header");

obj.setColumnCount(10);
obj.setRowCount(100);

// enable row selectors
obj.setSelectorVisible(true);
obj.setSelectorText(function(i){return this.getRowPosition(i)+1});

obj.setCellEditable(true);

// set headers width/height
obj.setSelectorWidth(28);
obj.setHeaderHeight(20);

document.write(obj);

// this will show only 5 specific columns
obj.setColumnIndices([0,2,3,4,5]);

document.write("<br>");

var label = new AW.UI.Label;
document.write(label);

// control activated/deactivated (receives/looses focus)

obj.onControlActivated = function(){
label.setControlText("Control activated");
}

obj.onControlDeactivated = function(){
label.setControlText("Control deactivated");
}

// editing starts/ends (F2, Enter, just start typing)
/*

obj.onCellEditStarted = function(text, col, row){
label.setControlText("Edit started - text: " + text + ", col: " + col + ", row: " + row);
}

obj.onCellEditEnded = function(text, col, row){
label.setControlText("Edit ended - text: " + text + ", col: " + col + ", row: " + row);
}

// changing cell text

obj.onCellTextChanged = function(text, col, row){
label.setControlText("Cell text changed - text: " + text + ", col: " + col + ", row: " + row);
}
// validating (Enter)

obj.onCellValidating = function(text, col, row){
var value = Number(text);
if (!(value > 100) || !(value < 1000)) {
label.setControlText("Invalid value - " + text + ", should be between 100 and 1000");
return true;
}
}
*/

obj.onCellValidated = function(text, col, row){
label.setControlText("Cell validated - text: " + text + ", col: " + col + ", row: " + row);
}

</script>
</body>
</html>
Michael L
Tuesday, February 7, 2006

i think this line in the style block is the culprit

.aw-column-1 {width: 200px;}

i had column 1 hidden using setcolumnindeces but still specifying a style. that seems to crash it. as soon as i remove the style. it doesn't crash anymore.
Tuesday, February 7, 2006



This topic is archived.

Back to support forum

Forum search