'/@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@/ Function newGUID() Dim Guid, RSGUID Guid = Server.CreateObject("scriptlet.typelib").Guid Guid = Left(Guid, InStr(Guid, "}")) newGUID = Guid newGUID = Replace(newGUID, "{", "") newGUID = Replace(newGUID, "}", "") newGUID = Replace(newGUID, "-", "") newGUID = LCase(newGUID) Set Guid = Nothing End Function '/@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@/ Public Function nz(Value, IfNullValue) If IsNull(Value) Then Nz = IfNullValue Else Nz = Value End Function '/@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@/ Public Function cSQLString(Value) cSQLString = Replace(Value,"'", "''") End Function '/@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@/ Public Function NzEmptyString(Value, IfEmptyValue) If cstr(Value) = "" Or cstr(Value) = "0" Then NzEmptyString = IfEmptyValue Else NzEmptyString = Value End Function '/@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@/ Public Function Iif(Value, TrueValue, FalseValue) Value = nz(Value, false) If CBool(Value) Then Iif = TrueValue Else Iif = FalseValue End Function '/@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@/ Function Choose(PairKeyValue, Value) Dim mArrayKeyValue, mIdx mArrayKeyValue = Split(PairKeyValue, ";") For mIdx = 0 to ubound(mArrayKeyValue) Step 2 if cstr(mArrayKeyValue(mIdx)) = cstr(nz(Value, "")) then Choose = mArrayKeyValue(mIdx + 1) Exit For end if Next End Function '/@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@/ Function CreateOptionList(Source, Value) Dim mOptionList, mArraySource, mIdx If TypeName(Source) = "Recordset" Then Do Until Source.EOF if cstr(Source(0)) = cstr(nz(Value, "")) then mOptionList = mOptionList & "