NamedTableRegion

File Object Type

A Named Table Region defines a group of cells in a table or spreadsheet.

You can use regions to name groups of numbers for calculations, or you can use the named region as a lookup function for the information inside.

Define a named region:
  1. Select the range of cells you wish to use.
  2. In the toolbar, select Table>Define Region.

The region is now created with a default name, e.g. Region2.

Name a region:
  1. After following the steps above, select the region by clicking on the label.
  2. Open the properties window.
  3. Edit the Name property.
Use a named region in place of a range of cells:
  1. Select the region and open the properties window.
  2. Click the Headers property neat the top.
  3. Change Count from 1 to 0.
  4. Use the named region in a formula as you would a named array or range of cells.

Note that you can achieve a similar effect by naming a range of cells in a formula, e.g. numbers = B3:C7

Use a named region as a lookup function:

For cells with headers in the top line and the lookup values in the first column:

  1. Create the region using the steps above.
  2. In a formula, use the region name like a function.
    • The first input is the lookup value, and it should match a cell in the first column.
    • The second input is the lookup column, and it should match one of the headers.
    • Note that for text values, quotation marks are needed to specify the input as text.

Note that a similar thing can be accomplished by defining a custom function using Vlookup and Match.

For a region with headers and lookup values in different locations in the range (e.g. headers on the left or lookup values in the second column):

  1. Create the region.
  2. Select the region and open the properties window.
  3. Select the Headers property and edit the Side to match the header location.
  4. Edit the Lookup Fields property to match which row/column the lookup values should be in.
  5. Use the region as a function where the first input is the lookup value, and the second input is the header name.
See also:

You can refer to this file object type in any formula, macro, module, or other script in Blockpad. You can use either its name or its full path:

  • To refer to it by name, use NamedTableRegion (make sure the library Library.Docs.Objects is included with Include Libaries)
  • To refer to it by its full path, use Library.Docs.Objects.NamedTableRegion

 

See also: