Expand All

Basics

Formatting

Context menu

Drag n Drop

Spreadsheet

Tabs

Export

Layouts

RTL Layout

Rows

Paging

Big data

Columns

Cells

Inline editing

Row Grouping

Pivot

Sorting

Filter

Selections

Nesting / Row details

Tree grid

Charts

Angular

React React

Vue Vue

Knockout

;

📊 jQuery Grid – Cell Selection Features

jQuery Grid (pqGrid) provides Excel-like cell selection capabilities that allow users to interact with grid data efficiently. Below are the detailed features:


🔹 Types of Cell Selection

  • Single Cell Selection
    • Click on a cell to select it.
  • Multiple Cell Selection
    • Hold Ctrl (Windows) or Cmd (Mac) and click to select multiple non-contiguous cells.
  • Range Selection
    • Click and drag across cells to select a rectangular range.
  • Select All
    • Use Ctrl + A (Windows) or Cmd + A (Mac) to select all cells in the grid.

🔹 Keyboard Shortcuts

  • Copy Selection → Ctrl + C
  • Select All Cells → Ctrl + A / Cmd + A
  • Navigation → Arrow keys move the active cell focus.

🔹 Programmatic Selection

pqGrid allows developers to select cells programmatically via API methods:

  • Range(...).select() → Select a cell or multiple cells.
  • Range({r1, c1, r2, c2}) → Define a rectangular range of cells.
  • getSelection() → Retrieve currently selected cells.
  • Selection().clear() → Clear selection.

🔹 Range Object

The Range API enables collective manipulation of selected cells:

  • Properties:
    • r1 → Starting row index
    • c1 → Starting column index
    • r2 → Ending row index
    • c2 → Ending column index
    • rc → Row count
    • cc → Column count
  • Example:
    grid.Range({ r1: 2, r2: 4 }).select(); // Select rows 2 to 4
    grid.Range({ r1: 1, c1: 1, r2: 3, c2: 3 }).select(); // Select a 3x3 block
    
";

Select Row Index:  Select Field: 

selectChange Event: