PDA

View Full Version : Oorang: A query about your GUID program



RonMcK
06-30-2010, 08:30 PM
Oorang,

I borrowed your code from your kb article: Create a GUID (Globally Unique Identifier). I'm using it in a vba macro that reads through a file and assigns a GUID to any record in the file that doesn't have one.

I noticed that your code produces GUIDS that are capitalized; is there a way (short of resorting to regular expressions) to get the GUID in lower case?

Thanks,

Bob Phillips
06-30-2010, 11:56 PM
Why notjust



Public Function GetGUID() As String
GetGUID = LCase(Mid$(CreateObject("Scriptlet.TypeLib").GUID, 2, 36))
End Function

RonMcK3
07-01-2010, 08:35 AM
Bob,

Yes, why not.

(I'll just die of embarrassment, now, and not blame the late hour and my brain having shut down for the night, etc.)

Thanks,