Getting an Excel Worksheet's Row
This procedure finds a row in a worksheet that contains a specific value.
Option 1: By Row Number
Syntax
get the worksheet's row
the row number is {number}
Inputs
number
: The row number.
Option 2: By Column Label & Cell Value
Syntax
get the worksheet's row
the column label is "{label}"
the cell value is "{value}"
Inputs
label
: The label of the column, in quotes. Example:A
,AE
,D
value
: The specific value of the cell in the target row that you want to retrieve, in quotes.
Examples
Given the following table:
A
B
C
1
Character
House
Favorite Spell
2
Harry Potter
Gryffindor
Expelliarmus
3
Hermione Granger
Gryffindor
Alohomora
4
Ron Weasley
Gryffindor
Riddikulus
5
Luna Lovegood
Ravenclaw
Expecto Patronum
Here are two examples on how to retrieve row #5:
By Row Number
get the worksheet's row
the row number is 5
By Column Label & Cell Value
get the worksheet's row
the column label is "B"
the cell value is "Ravenclaw"
Last updated
Was this helpful?