esProc Getting Started: Types of Cells

esProc 389 0

In esProc, cells are automatically classified into different types according to their values or the expressions they contain. In a cellset, each type of cell has its own appearance, which highlights the code in the cells.

1.Types of cells

1.1    Constant cell

A cell in which the cell string can be interpreted as the constant is called a Constant Cell. Its cell value is the constant.

The constant cell has the following types of values:


The text of a constant cell is in pink by default. Depending on the data in the cell, its value will be interpreted as various data types. For the unrecognized data, the value will be taken as the string.
Note:The representation style of 3% is unacceptable in any expression, but it is acceptable in the constant cell.

Please note the common reserved words below and keep in mind that they are case-sensitive!

  • null

Null value; the cell value of any empty cell is always the null

  • true


  • false


1.2 String constant cell

A string constant cell is the cell whose cell string starts with single quote ‘, indicating it is a constant cell with a string value. The cell value is a string composed of those characters after the single quote. In this case, all characters following the single quote will be parsed as string, not requiring any additional quotes, escape characters, etc.

‘abc\d    String abc\d

‘1234.5   String 1234.5


1.3 Computational cell

A computational cell is the cell whose cell string starts with =, and that is used for computing an expression. Its cell value is the computed result of the expression, which can reference cell values of other cells.

The text of the computational cell is in black by default.

Click Play button to execute the code and you will find that the background of the computational cell turns to light yellow, indicating its cell value has been computed.Click the cell with cell value. In the value view section, the current cell value will be displayed for you to view the computed result.


In the expression, you can use various basic operators to compute cell value:

  • a+ba-ba*ba/b

Add, subtract, multiply, and division operations.
=3*4    12
=1+2*3   7

  • a%b

Seek the remainder of a divided by b.
=121%11      0, which indicates 121 is a multiple of 11, and is divisible by 11
=100%7       2

  • a\b

Integer division, in which the integer parts of both a and bare kept. The integer part of the result will be returned after division.
=11\4       2, cut off the decimal part of the result

=6.1\2.9      3, which is equal to 6\2, the result is 3

  • s1+s2

Concatenate string s1 and s2. Note that the string will be ignored if added to a real number.
=”Stephen”+” “+”Rolfe”     String Stephen Rolfe
=”A”+3                                   Integer 3, string “A” is ignored
=”A”+string(3)                    String A3. If you do need to concatenate the string and the real number, please convert the real number to string first.

1.4 Executable cells

An Executable cell is the cell whose cell string starts with >, in which certain actions will be executed. The executable cell has no cell value. If an executable cell starts with one of the reserved words, like if, for, etc. then >can be omitted.

The code in an executable cell can be used to modify the value of another cell.

In the executable cells, the cells can be used as variables.


1.5 Comment cells

A comment cell is the cell whose cell string starts with /.Its cell value is null.
Comment cells will be ignored during execution.
The text of comment cells is in green by default.


2. Setthe appearance of different types of cells

esProc provides the users with options to set the font styles and the foreground/background color of different types of cells.Click the Tool ->Options. On the Appearance tab, you can view and modify settings.


Leave a Reply

Hi,You need to fill in the Username and Email!

  • Username (*)
  • Email (*)
  • Website