Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
425
how to select row and a cell
posted

I have the grid set to selectrow on cell click.  So the whole row backcolor turns blue.  But now I want the actual cell you clicked on to be selected as well.  This cell should have a white border around it.  I'm not sure if the grid supports this or if I have to catch some click side events and manually change the styles.

Thanks,

Eric

Parents
No Data
Reply
  • 3732
    posted

    Hi Eric,

    The CellClick event can be handled on the Client Side for  UltraWebGrid to achieve this functionality. Following is a code snippet.

    function UltraWebGrid1_CellClickHandler(gridName, cellId, button)

    {

     

    var cell = igtbl_getCellById(cellId);

    cell.Element.style.backgroundColor = "Red";

    cell.Element.style.borderColor = "Yellow";

     

    }

    You can include the ClientSide Event Handler for UltraWebGrid in design view by following the steps:

    1) Browse through the properties and find DisplayLayout and Expand it

    2) Locate the ClientSideEvents and expand it

    3) Find the CellClickHandler and click on the drop down and add a new handler

    This creates the method signature in the HTML mark up.

    I hope this helps.

     

Children