sanjshah
10 Dec 2007, 9:40 AM
Hi, I'm using the 'Array Grid' example to understand how the grid work, I have changed some of the testing to the following:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>Array Grid Example</title>
<link rel="stylesheet" type="text/css" href="exttools/ext-2.0/resources/css/ext-all.css" />
<script type="text/javascript" src="exttools/ext-2.0/adapter/ext/ext-base.js"></script>
<script type="text/javascript" src="exttools/ext-2.0/ext-all.js"></script>
<script type="text/javascript">
/*
* Ext JS Library 2.0
* Copyright(c) 2006-2007, Ext JS, LLC.
* licensing@extjs.com
*
* http://extjs.com/license
*/
Ext.onReady(function(){
Ext.state.Manager.setProvider(new Ext.state.CookieProvider());
var myData = [
['Company1','user2@company1.com','Surname1','Firstname1','asdase'],
['Company2','user1@company2.com','Surname2','Firstname2','gdfewe']
];
// create the data store
var store = new Ext.data.SimpleStore({
fields: [
{name: 'company'},
{name: 'email'},
{name: 'surname'},
{name: 'firstname'},
{name: 'password'}
]
});
store.loadData(myData);
// create the Grid
var grid = new Ext.grid.GridPanel({
store: store,
columns: [
{id:'company',header: "Company", width: 160, sortable: true, dataIndex: 'company'},
{header: "Email", width: 75, sortable: true, dataIndex: 'email'},
{header: "Surname", width: 75, sortable: true, dataIndex: 'surname'},
{header: "Firstname", width: 75, sortable: true, dataIndex: 'firstname'},
{header: "Password", width: 85, sortable: true, dataIndex: 'password'}
],
stripeRows: true,
autoExpandColumn: 'company',
height:400,
width:600,
title:'Users in System'
});
grid.render('grid-example');
grid.getSelectionModel().selectFirstRow();
});
</script>
<link rel="stylesheet" type="text/css" href="exttools/ext-2.0/examples/grid/grid-examples.css" />
<link rel="stylesheet" type="text/css" href="exttools/ext-2.0/examples/examples.css" />
<script type="text/javascript" src="exttools/ext-2.0/examples/examples.js"></script>
</head>
<body>
<h1> </h1>
</body>
</html>
All works well except when I try to drag a column, and when I click the dropdown arrow, I can see the menu and hide unhide columns but get the following error message:
Object doesn't support this object or method
This error only appears in IE
Any ideas?
Thanks
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>Array Grid Example</title>
<link rel="stylesheet" type="text/css" href="exttools/ext-2.0/resources/css/ext-all.css" />
<script type="text/javascript" src="exttools/ext-2.0/adapter/ext/ext-base.js"></script>
<script type="text/javascript" src="exttools/ext-2.0/ext-all.js"></script>
<script type="text/javascript">
/*
* Ext JS Library 2.0
* Copyright(c) 2006-2007, Ext JS, LLC.
* licensing@extjs.com
*
* http://extjs.com/license
*/
Ext.onReady(function(){
Ext.state.Manager.setProvider(new Ext.state.CookieProvider());
var myData = [
['Company1','user2@company1.com','Surname1','Firstname1','asdase'],
['Company2','user1@company2.com','Surname2','Firstname2','gdfewe']
];
// create the data store
var store = new Ext.data.SimpleStore({
fields: [
{name: 'company'},
{name: 'email'},
{name: 'surname'},
{name: 'firstname'},
{name: 'password'}
]
});
store.loadData(myData);
// create the Grid
var grid = new Ext.grid.GridPanel({
store: store,
columns: [
{id:'company',header: "Company", width: 160, sortable: true, dataIndex: 'company'},
{header: "Email", width: 75, sortable: true, dataIndex: 'email'},
{header: "Surname", width: 75, sortable: true, dataIndex: 'surname'},
{header: "Firstname", width: 75, sortable: true, dataIndex: 'firstname'},
{header: "Password", width: 85, sortable: true, dataIndex: 'password'}
],
stripeRows: true,
autoExpandColumn: 'company',
height:400,
width:600,
title:'Users in System'
});
grid.render('grid-example');
grid.getSelectionModel().selectFirstRow();
});
</script>
<link rel="stylesheet" type="text/css" href="exttools/ext-2.0/examples/grid/grid-examples.css" />
<link rel="stylesheet" type="text/css" href="exttools/ext-2.0/examples/examples.css" />
<script type="text/javascript" src="exttools/ext-2.0/examples/examples.js"></script>
</head>
<body>
<h1> </h1>
</body>
</html>
All works well except when I try to drag a column, and when I click the dropdown arrow, I can see the menu and hide unhide columns but get the following error message:
Object doesn't support this object or method
This error only appears in IE
Any ideas?
Thanks