Conversione ASCII/ANSI nelle stringhe

Le seguenti funzioni convertono le stringhe da e verso codici ASCII o ANSI.

Funzione Asc (BASIC)

Restituisce il valore ASCII (American Standard Code for Information Interchange) del primo carattere di una stringa.

Funzione Chr

Restituisce il carattere corrispondente al codice specificato.

Funzione Str

The Str function converts the contents of variables into a string. It handles numeric values, dates, strings and currency values.

Positive numbers are preceded by a blank space. Negative numbers are preceded by a minus sign.

note

For numeric values the string returned by the Str function is locale-independent. Hence the dot is used as the decimal separator when needed.


If a string is passed as argument, it is returned without any changes.

Dates are converted into locale-dependent strings.

Funzione Val

Use the Val function to convert a string that represents a number into numeric data type.

note

The string passed to the Val function is locale-independent. This means that commas are interpreted as thousands separators and a dot is used as the decimal separator.


Funzione CByte

Converte una stringa o un'espressione numerica nel tipo di dati Byte.