Page 1 of 1

GUID - unique identifier

Posted: Tue May 13, 2014 9:09 pm
by eddy
source: http://stackoverflow.com/questions/1050 ... javascript

Code: Select all

Procedure.s GenerateGUID()
!return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function(c) {
!    var r = Math.random()*16|0, v = c == 'x' ? r : (r&0x3|0x8);
!    return v.toString(16);
!});
EndProcedure