Computer Performance, Windows 2003, Exchange 2003, Logon Scripts

Code Error 8004100E - Invalid Namespace Error

Troubleshooting Code 8004100E - Invalid Namespace Error

Introduction to Code 8004100E

Error code, 8004100E occurs when you execute a VBScript connecting to WMI (Windows Management Instrumentation).  This is a spelling error check the name of your CIMV2 connection.  Another problem can be an invalid namespace e.g. root\RSOP on a Windows 2000 machine.  (root\RSOP is O.K. on XP and Windows Server 2003)

The Symptoms you get Code Error 8004100E - Invalid Namespace Error

The script does not execute as you had hoped. Instead you get a Windows Script Host message box like this picture:

The Cause of Code 8004100E

Your VBScript contains a misspelled object name.  Code 8004100E is an unusual Error in that a number is returned rather than 'Syntax Error' or other message.

The Solutions

Check the class definitions in the WMI section of the your script.  Pay attention to detail, for example CIM2 or CIM2v are incorrect it should be cimv2 or CIMV2.  If you have an older system, make sure that the class is valid.

  ‡

Example of Error Code 8004100E Script

Note: The Line 13:  & strComputer & "\root\cim2")

It should be & strComputer & "\root\cimV2")

' Shell.vbs
' Sample VBScript to display very basic BIOS information
' Author Guy Thomas http://computerperformance.co.uk/
' Version 1.5 - December 2005
' ---------------------------------------------------------'
Option Explicit
Dim objWMIService, objItem, colItems, strComputer

' On Error Resume Next
strComputer = "."

Set objWMIService = GetObject("winmgmts:\\" _
& strComputer & "\root\cim2")
Set colItems = objWMIService.ExecQuery(_
"Select * from Win32_BIOS")

 

Correct Version

' Shell.vbs
' Sample VBScript to display very basic BIOS information
' Author Guy Thomas http://computerperformance.co.uk/
' Version 1.5 - December 2005
' --------------------------------------------------------------'
Option Explicit
Dim objWMIService, objItem, colItems, strComputer

' On Error Resume Next
strComputer = "."

Set objWMIService = GetObject("winmgmts:\\" _
& strComputer & "\root\cimv2")
Set colItems = objWMIService.ExecQuery(_
"Select * from Win32_BIOS")

 

Seven General Troubleshooting Strategies for 800 Errors

  1. Golden Rule - Break your script into sections

  2. Play the numbers game

  3. Try a Walk-Through

  4. If you are still stuck try a parallel approach

  5. Change of Scenery

  6. Avoid 'Over-think'

  7. Find a Sounding Board

Solarwinds IpMonitorTry a different solution, download SolarWinds ipMonitor

Here is my thinking, ipMonitor will give you valuable data about your network and servers.  This extra information just may unlock the solution to your error code.  One more thing, sometimes when troubleshooting you go around in circles; therefore if you try a different, but related approach, you may just crack the problem.  Free Download of SolarWinds ipMonitor (21 day eval).

Computer Training Software - Recommended Training VideosGuy Thomas recommends Computer Training Software

Their topics and material are ideal for getting you started with VBScript.  The videos are easy to follow and you can control the pace.  Try their free demo material and then see if you want to buy the full package. See more about VB Script Training CD.


Do you need extra help?

For interpreting the WSH messages check Diagnose 800 errors.

For general advice try my 7 Troubleshooting techniques

Give something back?

Would you like to help others?  If you have a good example of this error, then please email me, I will publish it with a credit to you:

 *


Google

Web  This website

Review of Orion NPMGuy Recommends: Orion's Network Performance Monitor (NPM)

Orion NPM is designed for detecting network outages.

Network-centric views (screenshot) make it easy to see what's working, and what needs your attention.

Download your free trial of Orion's network performance monitor

 

Home Copyright © 1999-2009 Computer Performance LTD All rights reserved

Please report a broken link, or an error.