Login Register

Grid

Disable Sorting on specific column.

Hi All,
I would like to disable sorting on a specific column. Could someone shed come light on how this can be achieved?

Regards,
Yazad K

WordWrap in Grid in FireFox

I have a small problem with grid on FireFox. The grid is contained as follows:
BorderContainer -> ContentPane -> Grid
I have 3 columns in my table and since I dont like using pixels but rather prefer percentage,
the columns' width are 60%,20% and 20% respectively. Still the cell width is not
enough for the full text to display in the 60% column.
In IE, I use the style word-wrap: break-word; because of which the contents in the cell
do not get truncated. However, the same gets truncated in FireFox.
Is there any solution to this problem?

Refreshing grid with a new selection of data from the server

Hi,

I am trying to do the following:

  1. Display an empty grid
  2. Let the user enter some selection criteria and then retrieve data from the server and populate the grid
  3. User can then enter new selection criteria and re-submit it.

Problem I am having is that I cannot find how to send the revised selection criteria to the server. Code behind my 'onClick' handler for the search button is:

currentModel = new dojox.grid.data.DojoData(null, null, {rowsPerPage: 20, store: custStore, query: {CustomerId: '*'}, clientSort: false});

Sort Grid by Selected Rows

Hello!

I'm trying to sort my grid based on selected rows. That is, I want all the selected rows to sort together at the top of the grid. Can anyone please provide me with some tips to make this happen?

Should I create a field/cell to hold a boolean value that is determined on selection and sort by that (like a checkbox)?

Any help is greatly appreciated.

Thanks,
-Tommy

How to get the parms passed to a query?

Hi all,
I hope someone can help me.
I'm a newbie, so please be patient with me...
I want to get the parameters sent to a query on a QueryReadStore, similarly as a location.search. I want the whole string (?parm1=value1?parm2=value2 and so on).
Is it possible?
For now, I've made a routine that reads the filter fields in the DOM, but I think maybe dojo can more easily give this info. Is it possible?

Thanks in advance,
P

Grid programmatically created IE problem (FF, Opera OK)

Hi,

I am creating a grid programmatically, it appears correctly in Firefox 2 and Opera 9.5, but I get this error in IE7: "Object doesn't support this property or method". This is the code:

// a grid view for the dimensions
var dimensionView = {
cells: [[
{name: 'Id', width: "8em", field: "id"},
{name: 'Name', width: "8em", field: "name"},
{name: 'Version', width: "7em", field: "version"},
{name: 'Agency Id', width: "7em", field: "agencyId"},
{name: 'Final', width: "7em", field: "isFinal"}
]]
};
dimensionLayout = [ dimensionView ];

Looking for an example to get values out of a cell

Anyone know of any good examples of how to get the value contained by a cell in a grid? Or a simpler problem that pertains to my situation: just how to get the value of the first cell when a row is selected?

Thanks!

dojox.grid.editors.bool not working properly

I am using the following code for my grid.

var view1 = {
cells: [[
{name: 'Sel', editor: dojox.grid.editors.bool , width: '16px'},
{name: 'str', field: "star", formatter: starFormatter, width: '16px'},
{name: 'read', field: "read", formatter: readFormatter, width: '16px'},
{name: 'Subject',width: "60%", field: "subject", styles: 'white-space: nowrap;'},

Navigating through cells with keyboard

Hello everyone,

I've created a grid with cells that can be edited.
I now want to add the ability to move from one cell to another using the keys UP, DOWN, LEFT and RIGHT

So I did this to catch the keyboard events :

dojo.connect(this.grid, 'onKeyDown', this, this._keyDown);

And for the _keyDown function :


_keyDown: function (e) {

switch (e.keyCode) {
case dojo.keys.UP_ARROW:
var selectedRow = parseInt(this.grid.selection.getSelected()[0]);

var nextRow = selectedRow - 1;
if (selectedRow > 0 && this.grid.edit.info.cell != null) {

Grid event onSet don't want be fired :/

Hi !

I've spend about 3hr to found out why the onSet event is never fired, I, desperatly, I ask for your help :)

So, here is my code :

function createGrid (oResponse, ioArgs) {
var grid = dijit.byId("grid");
var store = new dojo.data.ItemFileReadStore({data: oResponse });
var gridModel = new dojox.grid.data.DojoData(null, store, {query:{destination: '*'}, clientSort:true});
grid.setModel(gridModel);
grid.refresh();

dojo.connect(grid.model, 'onSet', onSetEvent);
//dojo.connect(grid, 'onSet', onSetEvent);
}

Syndicate content