Data Type Conversation

char()

Description

Converts a value to the char data type.

Syntax

char(x)

Parameters

x: a value of any type

Returns

char

byte()

Description

Converts a value to the byte data type.

Syntax

byte(x)

Parameters

x: a value of any type

Returns

byte

int()

Description

Converts a value to the int data type.

Syntax

int(x)

Parameters

x: a value of any type

Returns

int

word()

Description

Convert a value to the word data type or create a word from two bytes.

Syntax

word(x)

word(h, l)

Parameters

x: a value of any type

h: the high-order (leftmost) byte of the word

l: the low-order (rightmost) byte of the word

Returns

long()

word

long()

Description

Converts a value to the long data type.

Syntax

long(x)

Parameters

x: a value of any type

Returns

long

float()

Description

Converts a value to the float data type.

Syntax

float(x)

Parameters

fx: a value of any type

Returns

float