Gambas Documentation - /dev/api/name/gb.conv

/dev/api/name/gb.conv

# GB.Conv

int GB.Conv ( GB_VALUE *arg , GB_TYPE type )

Converts a Gambas value into another datatype.

* arg points at the Gambas value to be converted.
type is the Gambas datatype the value will be converted into.

This function returns a non-zero value if the conversion fails, and set the interpreter error flag. This way, you can return immediately from the method or the property if you want to signal the error.

Use this function to convert a Gambas value argument to another Gambas datatype.

### See also

- /wiki/api/cat/conv

- /wiki/api/cat/datatype