formula
wks.col.formula$
string
Read/write
Column formula as in Set (Column) Values or in F(x)= label row (see also Column Label Row Characters).
EX1
// 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
//define function in python field wks.col2.py$= "def add1(a): return [val+1 for val in a] "; //use the function above in column formula wks.col2.formula$="py.add1(A)";
wks.col.setformula, wks.col.py$, wks.col.script$