Foro

Ayuda con GridFilter

0
Hola chicos, quiero hacer el ejemplo de la rejilla para poder ordenarla, como este: <!-- m -->http://www.extjs.com/deploy/dev/example ... local.html<!-- m --> Pero me marca el error que aparece en la imagen que anexo: Mi codigo tmbn lo anexo Ayuda please =(
0
imagen??codigo?? no están <!-- s;) --><!-- s;) -->
0
<html> <head> <title>Prueba2</title> <meta name="GENERATOR" Content="Microsoft Visual Studio .NET 7.1"> <meta name="CODE_LANGUAGE" Content="C#"> <meta name=vs_defaultClientScript content="JavaScript"> <meta name=vs_targetSchema content="http://schemas.microsoft.com/intellisense/ie5"> <link rel="stylesheet" type="text/css" href="../ext-2.2/resources/css/ext-all.css" /> <script type="text/javascript" src="../ext-2.2/adapter/ext/ext-base.js"></script> <script type="text/javascript" src="../ext-2.2/ext-all.js"></script> <!--<script type="text/javascript" src="scripts/grid-filter-local.jss"></script>!--> <script type="text/javascript"> Ext.ns('com.quizzpot.tutorial'); Ext.BLANK_IMAGE_URL = '../ext-2.2/resources/images/default/s.gif'; com.quizzpot.tutorial.ArrayGridTutorial = { init: function(){ Ext.ns('com.quizzpot.tutorial'); com.quizzpot.tutorial.ArrayGridTutorial = { init: function(){ //data var myData = [ ['3m Co',71.72,0.02,0.03,'9/1 12:00am'], ['Alcoa Inc',29.01,0.42,1.47,'9/1 12:00am'], ['Altria Group Inc',83.81,0.28,0.34,'9/1 12:00am'], ['American Express Company',52.55,0.01,0.02,'9/1 12:00am'], ['American International Group, Inc.',64.13,0.31,0.49,'9/1 12:00am'], ['AT&T Inc.',31.61,-0.48,-1.54,'9/1 12:00am'], ['Boeing Co.',75.43,0.53,0.71,'9/1 12:00am'], ['Caterpillar Inc.',67.27,0.92,1.39,'9/1 12:00am'] ]; //creating the store var store = new Ext.data.ArrayStore({ fields: [ {name: 'company'}, {name: 'price', type: 'float'}, {name: 'change', type: 'float'}, {name: 'pctChange', type: 'float'}, {name: 'updated', type: 'date', dateFormat: 'n/j h:ia'} ] }); //loading the data from the array store.loadData(myData); //creates the selection model var mySelectionModel = new Ext.grid.CheckboxSelectionModel({singleSelect: false}); //Creando el objeto Ext.grid.GridPanel var grid = new Ext.grid.GridPanel({ title:'Companies', store: store, renderTo: 'frame', columns: [ new Ext.grid.RowNumberer(), //a number in each row mySelectionModel, //checkbox for {id:'company',header: "Company", width: 160, sortable: true, dataIndex: 'company'}, {header: "Price", width: 75, sortable: true, dataIndex: 'price'}, {header: "Change", width: 75, sortable: true, dataIndex: 'change'}, {header: "% change", width: 75, sortable: true, dataIndex: 'pctChange'}, {header: "Updated", width: 85, sortable: true, renderer: Ext.util.Format.dateRenderer('m/d/Y'), dataIndex: 'updated'} ], sm: mySelectionModel, stripeRows: true, height:250, width:550 }); } } Ext.onReady(com.quizzpot.tutorial.ArrayGridTutorial.init,com.quizzpot.tutorial.ArrayGridTutorial); } } Ext.onReady(com.quizzpot.tutorial.ArrayGridTutorial.init,com.quizzpot.tutorial.ArrayGridTutorial); //Arreglo bidimensional de datos var myData = [ ['3m Co',71.72,0.02,0.03,'9/1 12:00am'], ['Alcoa Inc',29.01,0.42,1.47,'9/1 12:00am'], ['Altria Group Inc',83.81,0.28,0.34,'9/1 12:00am'], ['American Express Company',52.55,0.01,0.02,'9/1 12:00am'], ['American International Group, Inc.',64.13,0.31,0.49,'9/1 12:00am'], ['AT&T Inc.',31.61,-0.48,-1.54,'9/1 12:00am'], ['Boeing Co.',75.43,0.53,0.71,'9/1 12:00am'], ['Caterpillar Inc.',67.27,0.92,1.39,'9/1 12:00am'] ]; //creando el repositorio de datos var store = new Ext.data.ArrayStore({ fields: [ {name: 'compania'}, {name: 'precio', type: 'float'}, {name: 'cambio', type: 'float'}, {name: 'pctCambio', type: 'float'}, {name: 'actualizado', type: 'date', dateFormat: 'n/j h:ia'} ] }); store.loadData(myData); //Creando el objeto Ext.grid.GridPanel var grid = new Ext.grid.GridPanel({ title:'Listado de Compañias', store: store, renderTo: document.body, columns: [ {id:'compania',header: "Compañia", width: 160, sortable: true, dataIndex: 'compania'}, {header: "Precio", width: 75, sortable: true, dataIndex: 'precio'}, {header: "Cambio", width: 75, sortable: true, dataIndex: 'cambio'}, {header: "% de cambio", width: 75, sortable: true, dataIndex: 'pctCambio'}, {header: "Actualizado", width: 85, sortable: true, renderer: Ext.util.Format.dateRenderer('m/d/Y'), dataIndex: 'actualizado'} ], stripeRows: true, height:250, width:500 }); </script> </head> <body MS_POSITIONING="GridLayout"> <form id="Form1" method="post" runat="server"> </form> </body> </html>
0
sorry no se adjunto el archivo, pero ahi esta =) La imagen me marca dos errores de Object not expected
0
[quote="pasblin"]imagen??codigo?? no están <IMG title=Wink alt=;) src="./images/smilies/icon_e_wink.gif">[/quote] <html> <head> <title>Prueba2</title> <meta name="GENERATOR" Content="Microsoft Visual Studio .NET 7.1"> <meta name="CODE_LANGUAGE" Content="C#"> <meta name=vs_defaultClientScript content="JavaScript"> <meta name=vs_targetSchema content="http://schemas.microsoft.com/intellisense/ie5"> <link rel="stylesheet" type="text/css" href="../ext-2.2/resources/css/ext-all.css" /> <script type="text/javascript" src="../ext-2.2/adapter/ext/ext-base.js"></script> <script type="text/javascript" src="../ext-2.2/ext-all.js"></script> <!--<script type="text/javascript" src="scripts/grid-filter-local.jss"></script>!--> <script type="text/javascript"> Ext.ns('com.quizzpot.tutorial'); Ext.BLANK_IMAGE_URL = '../ext-2.2/resources/images/default/s.gif'; com.quizzpot.tutorial.ArrayGridTutorial = { init: function(){ var myData = [ ['3m Co',71.72,0.02,0.03,'9/1 12:00am'], ['Alcoa Inc',29.01,0.42,1.47,'9/1 12:00am'], ['Altria Group Inc',83.81,0.28,0.34,'9/1 12:00am'], ['American Express Company',52.55,0.01,0.02,'9/1 12:00am'], ['American International Group, Inc.',64.13,0.31,0.49,'9/1 12:00am'], ['AT&T Inc.',31.61,-0.48,-1.54,'9/1 12:00am'], ['Boeing Co.',75.43,0.53,0.71,'9/1 12:00am'], ['Caterpillar Inc.',67.27,0.92,1.39,'9/1 12:00am'] ]; var store = new Ext.data.ArrayStore({ fields: [ {name: 'compania'}, {name: 'precio', type: 'float'}, {name: 'cambio', type: 'float'}, {name: 'pctCambio', type: 'float'}, {name: 'actualizado', type: 'date', dateFormat: 'n/j h:ia'} ] }); store.loadData(myData); //Creando el objeto Ext.grid.GridPanel var grid = new Ext.grid.GridPanel({ title:'Listado de Compañias', store: store, renderTo: document.body, columns: [ {id:'compania',header: "Compañia", width: 160, sortable: true, dataIndex: 'compania'}, {header: "Precio", width: 75, sortable: true, dataIndex: 'precio'}, {header: "Cambio", width: 75, sortable: true, dataIndex: 'cambio'}, {header: "% de cambio", width: 75, sortable: true, dataIndex: 'pctCambio'}, {header: "Actualizado", width: 85, sortable: true, renderer: Ext.util.Format.dateRenderer('m/d/Y'), dataIndex: 'actualizado'} ], stripeRows: true, height:250, width:500 }); } } Ext.onReady(com.quizzpot.tutorial.ArrayGridTutorial.init,com.quizzpot.tutorial.ArrayGridTutorial); </script> </head> <body MS_POSITIONING="GridLayout"> <form id="Form1" method="post" runat="server"> </form> </body> </html> aqui esta ya corregido amigo, sorry
0
ok <!-- s;) --><!-- s;) -->, de todas formas estas progrmando en .NET?? si es asi echa un vistazo a esto [url]http://www.coolite.com/[/url] [url]http://code.google.com/p/extsharp/[/url] [url]http://www.codeplex.com/ExtJsExtenderControl[/url]
0
[quote="pasblin"]ok <IMG title=Wink alt=;) src="./images/smilies/icon_e_wink.gif">, de todas formas estas progrmando en .NET?? si es asi echa un vistazo a esto <A class=postlink href="http://www.coolite.com/">http://www.coolite.com/</A> <A class=postlink href="http://code.google.com/p/extsharp/">http://code.google.com/p/extsharp/</A> <A class=postlink href="http://www.codeplex.com/ExtJsExtenderControl">http://www.codeplex.com/ExtJsExtenderControl</A>[/quote] asi es, es .NET y la base de datos esta en SQL Server 2005, si existe conexion con ella vdd? osea si puedo tomar los datos de ahi para usar Extjs?? Le hechare un vistazo a los links gracias <!-- s;) --><!-- s;) -->

¿Conoces a alguien que pueda responder esta pregunta? Comparte el link en Twitter o Facebook

Es necesario registrarse para poder participar en el foro! Si ya tienes una cuenta puedes entrar y comentar en este foro.