IPB

Google Frontpage Forums Unattended CD/DVD Guide
 
Reply to this topicStart new topic
> IE Script Error in wpi.hta "Invalid syntax" line 103 char 5
icnocop
post Jul 18 2008, 01:20 PM
Post #1


Newbie


Group: Members
Posts: 31
Joined: 10-June 08
Member No.: 196160
OS: XP Pro x64
Country Flag


Hi.

WPI v6.5.1 on Windows XP Professional x64 Edition with SP2 integrated produces "Invalid syntax" error in wpi.hta on line 103 char 5. (See attachment)

I am using RunOnceEx.cmd to run wpi in this manner:

%DVD%\WPI\WPI.hta timer=0

line 103: timerSecs = WPIcmdArgs[15];

However, if I run wpi.hta after manually finishing installing windows xp professional x64, I do not get this error.

Any ideas \ work-arounds?

This seems like an issue with Internet Explorer, but I'm not sure how to fix it.

Thank you.
Attached File(s)
Attached File  ScriptError.GIF ( 19.24K ) Number of downloads: 6
 
Go to the top of the page
 
+Quote Post
icnocop
post Jul 18 2008, 04:32 PM
Post #2


Newbie


Group: Members
Posts: 31
Joined: 10-June 08
Member No.: 196160
OS: XP Pro x64
Country Flag


Ok, it seems that the line number was misleading (as usual in javascript)

The script error actually occurs in core.js line 102:
var OSProps = GetObject("winmgmts:").InstancesOf("Win32_OperatingSystem");

I will try to troubleshoot this issue further, since maybe wmi is disabled on this machine or something.


QUOTE (icnocop @ Jul 18 2008, 12:20 PM) *
Hi.

WPI v6.5.1 on Windows XP Professional x64 Edition with SP2 integrated produces "Invalid syntax" error in wpi.hta on line 103 char 5. (See attachment)

I am using RunOnceEx.cmd to run wpi in this manner:

%DVD%\WPI\WPI.hta timer=0

line 103: timerSecs = WPIcmdArgs[15];

However, if I run wpi.hta after manually finishing installing windows xp professional x64, I do not get this error.

Any ideas \ work-arounds?

This seems like an issue with Internet Explorer, but I'm not sure how to fix it.

Thank you.

Go to the top of the page
 
+Quote Post
mritter
post Jul 20 2008, 10:05 AM
Post #3


WPI Co-Developer
Group Icon

Group: Software Developers
Posts: 654
Joined: 13-November 05
From: Bettendorf, IA
Member No.: 79628
OS: Vista Home Premium x64
Country Flag


That call has been on place for over 18 months, so I really don't think it is a problem with WPI, something you have done with your Windows DVD.

Open a command prompt window and launch it from there to see if you get the same error. Works fine for me.
Go to the top of the page
 
+Quote Post
mritter
post Jul 20 2008, 10:18 AM
Post #4


WPI Co-Developer
Group Icon

Group: Software Developers
Posts: 654
Joined: 13-November 05
From: Bettendorf, IA
Member No.: 79628
OS: Vista Home Premium x64
Country Flag


Read some where else about WMI not being started yet. Try this updated code in core.js
CODE
    // %OSLANG%
    var Enum, DtoH;

    CreateLocalArray();

    try
    {
        OSProps = GetObject("winmgmts:").InstancesOf("Win32_OperatingSystem");
        winMgts = new Enumerator(OSProps).item();

        // OSLanguage = 1033, 1036, ....
        // Language ID in Dec
        try
        {
            Enum = winMgts.OSLanguage;
        }
        catch(ex2)
        {
            Enum=1033;
        }
        DtoH = DecToHex(Enum);
        while (DtoH.length<4)
            DtoH = "0" + DtoH+"";

        for (var x=0; x<arrOSLang.length; x++)
        {
            if (arrOSLang[x].LCID == DtoH)
            {
                oslang=arrOSLang[x].TLA;
                oslocale=arrOSLang[x].Locale;
                break;
            }
        }

    }
    catch(ex)
    {
        oslang="ENU";
        oslocale="English - United States";
    }

The try/catch may prevent the error message, and default to "ENU" and "English - United States" for the language/locale.
Go to the top of the page
 
+Quote Post
icnocop
post Jul 20 2008, 09:33 PM
Post #5


Newbie


Group: Members
Posts: 31
Joined: 10-June 08
Member No.: 196160
OS: XP Pro x64
Country Flag


Ok, I've finally found a fix.

The root problem was that the WMI (Windows Management Instrumentation) service was missing and so I had to add these lines to RunOnceEx.cmd before launching wpi.hta:

REM Register WMI
cd /d %windir%\system32\wbem
for %%i in (*.dll) do RegSvr32 -s %%i
scrcons.exe /RegServer
unsecapp.exe /RegServer
winmgmt.exe /Regserver
wmiadap.exe /RegServer
wmiapsrv.exe /RegServer
wmiprvse.exe /RegServer

Thank you mritter for the info in your replies. smile.gif

QUOTE (icnocop @ Jul 18 2008, 03:32 PM) *
Ok, it seems that the line number was misleading (as usual in javascript)

The script error actually occurs in core.js line 102:
var OSProps = GetObject("winmgmts:").InstancesOf("Win32_OperatingSystem");

I will try to troubleshoot this issue further, since maybe wmi is disabled on this machine or something.


QUOTE (icnocop @ Jul 18 2008, 12:20 PM) *
Hi.

WPI v6.5.1 on Windows XP Professional x64 Edition with SP2 integrated produces "Invalid syntax" error in wpi.hta on line 103 char 5. (See attachment)

I am using RunOnceEx.cmd to run wpi in this manner:

%DVD%\WPI\WPI.hta timer=0

line 103: timerSecs = WPIcmdArgs[15];

However, if I run wpi.hta after manually finishing installing windows xp professional x64, I do not get this error.

Any ideas \ work-arounds?

This seems like an issue with Internet Explorer, but I'm not sure how to fix it.

Thank you.


Go to the top of the page
 
+Quote Post
icnocop
post Jul 21 2008, 05:58 AM
Post #6


Newbie


Group: Members
Posts: 31
Joined: 10-June 08
Member No.: 196160
OS: XP Pro x64
Country Flag


It seems there is a problem when (manually) adding the following two lines to the [Components] section of AMD64\winnt.sif (after nlite):
iis_smtp=On
iis_smtp_docs=On

The result is the "Invalid syntax" error in wpi.hta and the WMI service is missing.

I will start another thread in the nlite forum...

QUOTE (icnocop @ Jul 20 2008, 08:33 PM) *
Ok, I've finally found a fix.

The root problem was that the WMI (Windows Management Instrumentation) service was missing and so I had to add these lines to RunOnceEx.cmd before launching wpi.hta:

REM Register WMI
cd /d %windir%\system32\wbem
for %%i in (*.dll) do RegSvr32 -s %%i
scrcons.exe /RegServer
unsecapp.exe /RegServer
winmgmt.exe /Regserver
wmiadap.exe /RegServer
wmiapsrv.exe /RegServer
wmiprvse.exe /RegServer

Thank you mritter for the info in your replies. smile.gif

QUOTE (icnocop @ Jul 18 2008, 03:32 PM) *
Ok, it seems that the line number was misleading (as usual in javascript)

The script error actually occurs in core.js line 102:
var OSProps = GetObject("winmgmts:").InstancesOf("Win32_OperatingSystem");

I will try to troubleshoot this issue further, since maybe wmi is disabled on this machine or something.


QUOTE (icnocop @ Jul 18 2008, 12:20 PM) *
Hi.

WPI v6.5.1 on Windows XP Professional x64 Edition with SP2 integrated produces "Invalid syntax" error in wpi.hta on line 103 char 5. (See attachment)

I am using RunOnceEx.cmd to run wpi in this manner:

%DVD%\WPI\WPI.hta timer=0

line 103: timerSecs = WPIcmdArgs[15];

However, if I run wpi.hta after manually finishing installing windows xp professional x64, I do not get this error.

Any ideas \ work-arounds?

This seems like an issue with Internet Explorer, but I'm not sure how to fix it.

Thank you.



Go to the top of the page
 
+Quote Post

Google Frontpage Forums Unattended CD/DVD Guide

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



Lo-Fi Version Time is now: 7th January 2009 - 11:36 AM
All trademarks mentioned on this page are the property of their respective owners
MSFN is not affiliated with Microsoft
Copyright © 2001-2008 msfn.org
Privacy Policy