Function UuidToChar() Foundation

Convert a UUID to its readable representation

Syntax
UuidToChar( <xUUID> ) --> cUUID
Parameters
<xUUID>
<xUUID> is a binary character string with the length 16 which was created by the function UuidCreate() .
Return

This function returns a readable and printable representation of the UUID. The return value has the notation xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx. Any 'x' is a placeholder for a digit from '1' to '9' or for a character from 'a' to 'f'.

Description

This function transforms a Universally Unique IDentifier which was created by the function UuidCreate() to a readable and printable representation.

The inverse function of UuidToChar() is the function UuidFromChar() .

Examples
UuidToChar()
// Create a uuid and convert it to its human readable 
// representation. Then retransform to its binary 
// representation and compare it with the original value 

PROCEDURE Main 
   LOCAL xUUID, cUUID 

   xUUID := UuidCreate() 
   cUUID := UuidToChar( xUUID ) 
   ? xUUID == UuidFromChar( cUUID )  // result: .T. 

   WAIT 

RETURN 
Feedback

If you see anything in the documentation that is not correct, does not match your experience with the particular feature or requires further clarification, please use this form to report a documentation issue.