.net - WMI Provider load failure -
.net - WMI Provider load failure -
i getting next error code below, on "next line (line 10). ideas?
system.management.managementexception occurred   message=provider load failure    source=system.management   stacktrace:        @ system.management.managementexception.throwwithextendedinfo(managementstatus errorcode)        @ system.management.managementobjectcollection.managementobjectenumerator.movenext()    here code:
using mos managementobjectsearcher = new managementobjectsearcher("select * win32_process") each mo managementobject in mos.get()     dim name string = mo("name")     dim commandline string = mo("commandline")     if name = "rundll32.exe"         dim index integer         commandline = commandline.substring(index).tolower         processpath = commandline     end if   next end using       
https://msdn.microsoft.com/en-us/library/bb961987.aspx
wmi clients can provider load failure error when effort utilize functionality implemented in wmi provider leverages wmi provider extensions infrastructure. cause might improperly-registered dynamic-link library (dll). during installation of .net framework 3.5 (prior sp1), dll named system.management.instrumentation.dll not registered. perform registration, run regasm.exe tool providing total path dll argument. next procedure provides step-by-step directions register system.management.instrumentation.dll. register system.management.instrumentation.dll
click start, , select programs.
click microsoft visual studio 2008 , select visual studio tools.
on operating systems before windows vista, click microsoft visual studio 2008 command prompt open command prompt window. on windows vista, right-click microsoft visual studio 2008 command prompt , select run administrator open elevated command prompt window.
at command prompt, type "regasm %systemdrive%\program files\reference assemblies\microsoft\framework\v3.5\system.management.instrumentation.dll" , press enter. check message, types registered successfully. verify registration has been corrected, can run wsh script below. should output system.management.instrumentation .net framework 3.5 registered. .net wmi 
 
Comments
Post a Comment