Function UuidFromChar() Foundation
Convert a UUID to its binary representation
UuidFromChar( <cUUID> ) --> xUUID
The return value is a binary character string which can include any character from Chr(0) to Chr(255).
With the function UuidFromChar() a Universally Unique IDentifier can be transformed from its readable to its binary representation. This function is the inverse function of 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
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.