DotNet bug using Wbem?

C

ChrisWoodruff

Has anyone experienced this? I am using .NET 2003 creating a "ASP.NET
Web Application".

Basically if I call this once, it works. Call it a 2nd time and I get an
"unspecified COM error". If I close the IDE in between it will work
again (stopping and restarting the solution doesn't seem to help).

I have tried to keep this short - thanks for looking!

I have removed all code and am down to these few lines;

' ----- Add COM reference "Microsoft WMI Scripting V1.2 Library"
Dim objWbem As SWbemLocator
Dim objSvc As SWbemServices
Dim SD_Array As Object
Dim objTemp As Object

' ----- Connect to WMI Object, Get WMI Security Descriptor
objWbem = CreateObject("WbemScripting.SWbemLocator")

' (variables are passed in and all are type string)
objSvc = objWbem.ConnectServer(strPC, "root", strUser, strPass)
objTemp = objSvc.ExecMethod("__SystemSecurity=@", "GetSD")
SD_Array = objTemp.sd

Thanks
cw
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top