Does this mean you are sending back an object? request.Comment = "Mock comment"
request.Body = "This is a mock body text" If it does is the object returned visible and compliant? Davy -----Original Message----- From: "Greg Keogh" <g...@mira.net> Sender: ozdotnet-boun...@ozdotnet.com Date: Sun, 28 Nov 2010 15:39:02 To: 'ozDotNet'<ozdotnet@ozdotnet.com> Reply-To: ozDotNet <ozdotnet@ozdotnet.com> Subject: [OT] VBScript return string runtime error Folks, I'm using some VBSCript to drive a COM visible library and check it's working. But in the line in red below I get a runtime error. I'm just trying to get a string id back from the SendRequest call. If I remove the "id = " before the call then it works. What's crazy is that the previous DeleteRequest call returns a bool and it works. So why can I get a bool back from one call but not a string from the other call? set client = WScript.CreateObject("Foobar.ComClient.Client") WScript.Echo "Created COM client" flag = client.DeleteRequest("SomeKey") WScript.Echo "Delete return = " & flag : set request = WScript.CreateObject("Foobar.ComClient.Request") request.Comment = "Mock comment" request.Body = "This is a mock body text" WScript.Echo "Created request" : id = client.SendRequest(request) WScript.Echo "Returned request Id = " & id Created COM client Delete return = 0 Created request vbstest.vbs(15, 1) Microsoft VBScript runtime error: Invalid procedure call or argument: 'client.SendRequest' Greg