locked
Set selection on grid control RRS feed

  • Question

  • Hello,

     

    We have developed a custom add-in for ProClarity Desktop Professional 6.3 that utilizes the Grid control.  We've successfully used the KGrid.SelectedCellRange() method to retrieve the cells that a user has selected in the grid.  But we are now looking for a way to programmatically change which cells are selected, based on some calculations.  I don't see a way to set this, either through a property or a method.  Am I missing something?

     

    Thanks!

    -Dave

    Wednesday, June 25, 2008 3:20 PM

Answers

  • Unfortunately, there is no way to programmatically modify the selected range of cells (that I am aware of).  The KRect object does not respond to changes to its properties.  If you absolutely need those features, you will need to build your own Grid Plug-in.  I think the SDK still contains the FlexGrid plug-in sample which would get you started.

     

    Jason

    BTG Services

     

    Friday, July 18, 2008 11:17 PM

All replies

  • Interesting...I'm not sure I've ever seen an application like this, and I'm not sure it's possible in the way you describe it.  Can you tell me what your end goal is?  Perhaps there's another way to go about it.

     

    Wednesday, July 9, 2008 12:20 AM
  • Thanks for the reply.  Our end goal is rather complex, but I'll describe a couple of hypothetical situations:

     

    1. A user views a grid of results, and selects a range of cells.  The user then right-clicks on this range and selects a custom menu option that iterates through the selected cells finds the cell with the largest value.  The add-in clears the selection and changes the grid selection so only the cell with the largest value is selected.

     

    2. A user views a grid of results.  They are interested in doing something with an entire range of cells, maybe entire rows or columns.  We'd like to develop a right-click function that can "Select Entire Row" or "Select Entire Column" or even "Select Entire Grid".

     

    Are either of these possible?

     

    Thanks,

    -Dave

     

    Tuesday, July 15, 2008 5:27 PM
  • Unfortunately, there is no way to programmatically modify the selected range of cells (that I am aware of).  The KRect object does not respond to changes to its properties.  If you absolutely need those features, you will need to build your own Grid Plug-in.  I think the SDK still contains the FlexGrid plug-in sample which would get you started.

     

    Jason

    BTG Services

     

    Friday, July 18, 2008 11:17 PM