wks.col.type

Syntax

wks.col.type

Type

numeric

Access

Read/write

Description

Column type: 1 = Y, 2 = disregard, 3 = Y Error, 4 = X, 5 = Label, 6 = Z, and 7 = X Error.

Examples

EX1

//Active sheet column access by index
// Set col(1)'s short name in active sheet as "Time"
wks.col1.name$ = Time;

// You can reference another book, but the target sheet must still be active
// Set column 5 in the active sheet of Book5 to be an X column
Book5!wks.col5.type = 4;

// col0 to refer to last column
//set last column formula
wks.col0.formula$="A";

EX2

// Set every odd column as an X column
for( ii = 1 ; ii <= wks.ncols ; ii+=2)
{
   wks.col = ii;
   wks.col.type = 4;
}
// which is equivalent to
for( ii = 1 ; ii <= wks.ncols ; ii+=2)
{
   wks.col$(ii).type = 4;
}

EX3

This script sets column 1 of the active window to be an X column.
wks.col1.type = 4;

See also

wks.col.numerictype, wks.col.format, wks.col.iscat