internetexplorer.application activex component can't create object

I am getting the infamous 429 error with a new image of Windows 2003 Server.

I am sure this is an issue with the Windows 2003 Server image, so I have to figure out a work around to get this  to work.  No updates to the image are possible.  I have been searching for a solution for a couple of days and nothing I have tried has worked so any assistance you can provide is most welcome.

This script works just fine on my Windows 7 machine and used to work just fine on the previous image of Windows 2003 Server I had which is no longer available:

Err.Number: 429

Err.Description: "ActiveX component can't create object"

Here is the code:

On Error Resume Next
'
Set fsoObj = CreateObject("Scripting.FileSystemObject")
'
Dim objIE
'
Err.Clear
'
Set objIE = CreateObject( "InternetExplorer.Application" )
'
If ( Err.Number <> 0 ) Then
   '
   WScript.Echo "Number (" & Err.Number & ")" & vbCrLf _
              & "Description [" & Err.Description & "]"
   WScript.Quit
   '
End If
'
objIE.Navigate "about:blank"
objIE.Width          = 200
objIE.Height         = 300
'
Do Until objIE.ReadyState = 4
   WScript.Sleep 200
Loop
'
Do While objIE.Busy
   WScript.Sleep 200
Loop
'
bodyStr = javaScriptStr & "<table align='center'><tr><td align='center' colspan='2'>Click Run or Cancel</td></tr>" _
        & "<tr align='center'>" & vbCrLf _
        & "<td colspan='2'>" & vbCrLf _
        & "<input type='submit' value=' Run ' " & "OnClick='VBScript:OK.Value=1'>" & vbCrLf _
        & " &nbsp; &nbsp; " & vbCrLf _
        & "<input type='submit' value=' Cancel ' " & "OnClick='VBScript:CANCEL.Value=1'>" & vbCrLf _
        & "</td></tr>" & vbCrLf _
        & "</table>" & vbCrLf _
        & "<input type='hidden' id='CANCEL' name='CANCEL' value='0'>" & vbCrLf _
        & "<input type='hidden' id='OK' name='OK' value='0'>"

'
objIE.Document.Body.InnerHTML = bodyStr
objIE.Visible = True
'
Do While ( ( objIE.Document.All.CANCEL.Value = 0 ) AND ( objIE.Document.All.OK.Value = 0 ) )
   '
   WScript.Sleep 200
   '
   If Err Then ' user clicked red X (or alt-F4) to close IE window
      '
      objIE.Quit
      Set objIE = Nothing
      logFile.WriteLine Now & " - aborting input!"
      '
   End if
Loop
'
objIE.Quit
'


June 2nd, 2014 4:56pm

You are conveniently leaving out most of the important information.

Try just this on line in a single vbs file:

Set objIE = CreateObject( "InternetExplorer.Application" )

If it doesn't work you need to repair your system.

Free Windows Admin Tool Kit Click here and download it now
June 2nd, 2014 5:07pm

I tested this cleaned up version on WS2003.  It works exactly the same way as it does on Windows 8 and Windows 7.

Set objIE = CreateObject( "InternetExplorer.Application" )
objIE.Navigate "about:blank"
objIE.Width          = 200
objIE.Height         = 300
Do While objIE.Busy
   WScript.Sleep 200
Loop
bodyStr = javaScriptStr & "<table align='center'><tr><td align='center' colspan='2'>Click Run or Cancel</td></tr>" _
        & "<tr align='center'>" & vbCrLf _
        & "<td colspan='2'>" & vbCrLf _
        & "<input type='submit' value=' Run ' " & "OnClick='VBScript:OK.Value=1'>" & vbCrLf _
        & " &nbsp; &nbsp; " & vbCrLf _
        & "<input type='submit' value=' Cancel ' " & "OnClick='VBScript:CANCEL.Value=1'>" & vbCrLf _
        & "</td></tr>" & vbCrLf _
        & "</table>" & vbCrLf _
        & "<input type='hidden' id='CANCEL' name='CANCEL' value='0'>" & vbCrLf _
        & "<input type='hidden' id='OK' name='OK' value='0'>"

objIE.Document.Body.InnerHTML = bodyStr
objIE.Visible = True
On Error Resume Next
Do While ( ( objIE.Document.All.CANCEL.Value = 0 ) AND ( objIE.Document.All.OK.Value = 0 ) )
   If Err Then ' user clicked red X (or alt-F4) to close IE window
      WScript.Echo Now & " - aborting input!"
      WScript.Quit
   End if
   WScript.Sleep 200
Loop
WScript.Echo Now & " - EXITING!"
objIE.Quit

June 2nd, 2014 5:31pm

I tried the simple script you suggested and it does not work.

As I mentioned, I know my system is broke, but I need help finding what and where.

Thanks

Free Windows Admin Tool Kit Click here and download it now
June 2nd, 2014 7:48pm

I have tried that and it does not work in my copy of WS2003 and I need help finding out why.

Can you tell me where to go look to find out why this does not work on WS2003 image I have?

Thanks

June 2nd, 2014 7:50pm

If it works on other peoples' Windows Server 2003 but not on yours, then there's something different about your image that prevents the HTA from working correctly. It is incredibly difficult, if not impossible, for us to reproduce the exact conditions of your server image in order to help you reproduce and troubleshoot the problem. Sorry but it sounds like you are stuck.
Free Windows Admin Tool Kit Click here and download it now
June 2nd, 2014 8:14pm

I noticed you keep unmarking the answer. Do you still need help with this question?

I don't think there's any other answer we can give you except to say that your server image has something broken and we cannot reprodu

June 19th, 2014 11:26pm

I don't think that not being able to reproduce a problem is a solution.

That is why I keep removing this as a 'solution'.

I guess I have to leave it as is.

Free Windows Admin Tool Kit Click here and download it now
July 2nd, 2014 11:08am

I agree that not being able to reproduce the problem isn't a solution. The solution is to fix whatever is broken in your server image. The problem is we have no possible way of knowing what that is. Once you find out what exactly is broken and fix it, you can post an updated answer.

July 2nd, 2014 11:12am

I don't think that not being able to reproduce a problem is a solution.

That is why I keep removing this as a 'solution'.

I guess I have to leave it as is.

  • Marked as answer by Rich Molumby Wednesday, July 02, 2014 3:04 PM
Free Windows Admin Tool Kit Click here and download it now
July 2nd, 2014 6:04pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics