if MethodName = 'STRTOHEX' then Result:=StringToHex(Params[0],'') else
fsScript.AddMethod('function StrToHex(Str:String):String',CallMethod);