Jump to content

dbgrid column pointer


jahlxx

Recommended Posts

Hi.

 

I have this for my dbgrids:

 

  UniSession.AddJS('var ColCells = ".x-grid-cell-headerId-"+'+ (Sender as TUniDBGrid).JSName +'.columnManager.columns['+ IntToStr(colindx) +'].id;'+
                               'Ext.select(ColCells).setStyle("cursor", "pointer");'
  );

 

To change pointer in some columns depending some options in run-time.

 

I don't know why, but this have been working and don't know when or in wich update this don't work.

 

Any idea?

 

Thanks.

 

Link to comment
Share on other sites

Hi,

 

Try,

 UniSession.AddJS('var ColCells = ".x-grid-cell-"+'+ (Sender as TUniDBGrid).JSName +'.columnManager.columns['+ IntToStr(colindx) +'].id;'+
                  'Ext.select(ColCells).setStyle("cursor", "pointer");'
 );

Or another solution I think:

procedure TMainForm.UniDBGrid1DrawColumnCell(Sender: TObject; ACol,
  ARow: Integer; Column: TUniDBGridColumn; Attribs: TUniCellAttribs);
begin
  if ACol = 1 then
    Attribs.Style.Style := 'cursor:pointer'

end;
Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
×
×
  • Create New...