I am trying to convert this VB script to kiX, i am gettting this error message

ERROR : IDispatch pointers not allowed in expressions!
Script: D:\kix\pingvb.KIX
Line : 10

Please help!!!
 PHP:
$objExcel = CreateObject('Excel.Application') $objExcel.Visible = True $objExcel.Workbooks.Add $intRow = 2 $objExcel.Cells(1, 1).Value = "Machine Name" $objExcel.Cells(1, 2).Value = "Results" $Fso = CreateObject('Scripting.FileSystemObject') $InputFile = $fso.OpenTextFile('d:\kix\MachineList.Txt') Do While NOT ($InputFile.atEndOfStream) $HostName = $InputFile.ReadLine $WshShell = WScript.CreateObject('WScript.Shell') $Ping = $WshShell.Run("ping -n 1 " $HostName, 0, True) $objExcel.Cells($intRow, 1).Value = $HostName Select Case $Ping Case 0 $objExcel.Cells($intRow, 2).Value = "On Line" Case 1 $objExcel.Cells($intRow, 2).Value = "Off Line" EndSelect $intRow = $intRow + 1 Loop $bjExcel.Range("A1:B1").Select $objExcel.Selection.Interior.ColorIndex = 19 $objExcel.Selection.Font.ColorIndex = 12 $objExcel.Selection.Font.Bold = True $objExcel.Cells.EntireColumn.AutoFit
_________________________
“I’ll not change you unless you don’t have intention to change yourself” --H:Quran