# SetSelectedRange

Use the SetSelectedRange method to set the specified range of cells as selected. Learn its syntax and parameters in documentation.

## Content

Sets the specified range of cells as selected.

## Syntax

[JavaScript]

```javascript
FpSpread1.SetSelectedRange(row,column,rowCount,columnCount);
```

## Parameters

***row***
Integer, starting row index
***column***
Integer, starting column index
***rowCount***
Integer, number of rows in selection
***columnCount***
Integer, number of columns in selection

## Return Type

None

## Remarks

This method selects the specified range of cells on the displayed page on the client. The row and column indexes, as well as the row and column counts must be valid. This method does not cause a postback to occur.

## Example

This is a sample that contains the method. On the client side, the script that contains the method would look like this:

```javascript
<script type="text/javascript">
   function setFirstRange() {
      FpSpread1.SetSelectedRange(5,3,12,10);
   }
</script>
```

## See Also

[GetSelectedRange](/spreadnet/docs/latest/online-asp/overview/spweb-clientscriptref/clientscript-members/clientscript-allmeths/CSSR-GetSelectedRange)
[Scripting Members](/spreadnet/docs/latest/online-asp/overview/spweb-clientscriptref/clientscript-members)