>PROCEDURE GuidFormat3 >LPARAMETERS m.lcBuffer >LOCAL m.lcPK,m.i,m.lnHex,m.lnUpper,m.lnLower >m.lcPK=SPACE(0) >FOR m.i=1 TO 16 > m.lnHex = ASC(SUBSTR(m.lcBuffer,m.i,1)) > m.lnUpper = INT(m.lnHex/16) > m.lnLower = m.lnHex - (m.lnUpper*16) > m.lcPK = m.lcPK + SUBSTR('0123456789ABCDEF',m.lnUpper + 1,1) + ; > SUBSTR('0123456789ABCDEF',m.lnLower + 1,1) >ENDFOR >RETURN m.lcPKGuidFormat3: This is not reversing the string, and its not the standard character representation of a guid, I wonder what are you trying to do here.
Local m.lcGuid As String, m.lnPointer As Integer m.lcGuid = Replicate(Chr(0xFF), 16) apiUuidCreate(@m.lcGuid) m.lnPointer = 0 apiUuidToString(m.lcGuid, @m.lnPointer) ?Sys(2600, m.lnPointer, 36) ******************************************************************************** Function apiUuidCreate(m.Uuid) ******************************************************************************** Declare Integer UuidCreate In rpcrt4.Dll As apiUuidCreate ; String @Uuid Return apiUuidCreate(@m.Uuid) Endfunc ******************************************************************************** Function apiUuidToString(m.Uuid, m.StringUuid) ******************************************************************************** Declare Integer UuidToString In rpcrt4.Dll As apiUuidToString ; String Uuid, ; Integer @StringUuid Return apiUuidToString(m.Uuid, @m.StringUuid) EndfuncThis returns something like this: