Jump to content
Strawberry Orange Banana Lime Leaf Slate Sky Blueberry Grape Watermelon Chocolate Marble
Strawberry Orange Banana Lime Leaf Slate Sky Blueberry Grape Watermelon Chocolate Marble

MSFN is made available via donations, subscriptions and advertising revenue. The use of ad-blocking software hurts the site. Please disable ad-blocking software or set an exception for MSFN. Alternatively, register and become a site sponsor/subscriber and ads will be disabled automatically. 

Sign in to follow this  

[Solved] Faster computer, causes command lines to skip

Recommended Posts


I'm curious how to resolve... essentially everything works like it should on a slower machine, yet when I replicate installation on a newer build, command lines which should be executed sequentially, some get missed out, as if the computer is too fast to keep up. The nlite install is XP and is identical in each case, the only thing different is newer hardware.

It's actually a list of command lines in a "register.bat" (not sure if .cmd works better).

This is executed after completed extraction of a SFX.exe, a cabinet called upon by RunOnce utility at setup. Everyhting works flawlessly on an older laptop, both a single and a dual core, just not this 3GHZ quad core, 8GB ram machine.

This is hardly consequential but it's a VBS script which I already spent considerable time trying to get going (let's waste more heh).

Essentially dummy .zip file is called open, following VBS script closes it immediately after, this initializes .zip folders in XP before logon, which would otherwise show unrecognized because of nlite (I left that option unticked but you can't be sure with nlite!)

@echo off
REGSVR32.EXE /s MpaDecFilter.ax
REGSVR32.EXE /s DSMSplitter.ax
REGSVR32.EXE /s DSMMuxer.ax
REGEDIT /s hubble.reg
REGEDIT /s AddressBar.reg
REGEDIT /S Qlaunch.reg
REGEDIT /S misc.reg
REGEDIT /S color.reg
REGEDIT /s mplayerc.reg
%windir%\system32\cmd.exe /C "START /WAIT CScript %windir%\system32\ZipClose.vbs //NoLogo"
del %systemdrive%\windows\system32\*.reg

Is there something I can put between the lines, a delay perhaps or is this something different? I'm concerned that a machine can just run missing out entire chunks of code - makes you question the integrity of XP sometimes


Ideas Appreciated


Edited by shorterxp

Share this post

Link to post
Share on other sites

Possibly you have EXTENSIONS ENABLED.

Use Start /Wait "PUT A TITLE HERE" REGSVR32.EXE /s MpaDecFilter.ax etc..


Does it make a difference?

Side notes:

What is the point of using %Windir$\System32\cmd.exe?

IF the batch runs, a cmd.exe has been already started.

You normally use .cmd for batch files intended to be run under NT and .bat for batch files intended to be run under DOS and 9x/Me.

In theory .bat is associated to command.com, whilst .cmd is associated to cmd.exe.


Share this post

Link to post
Share on other sites


Gee extensions never thought of that. They are off on default - is it more appropriate to ignore them in the lines then?

IIRC this issue seems be specific to BATS executed from within/after SFX extraction.

"%Windir$\System32\cmd.exe" and what follows is a example I copied/pasted. Should I get rid of it?

I will give your /wait suggestion a go. Thanks for the link.

Keeping in mind nlite.cmd from runonce calls out SFX which in turn executes the problematic .bat... Are you suggesting to put .cmd in the SFX instead?

I think DOS is gui-less windows, therefor my gut says I should use .cmd. Wonder why bat be so popular(?)

Another occasion you have helped me out buddy, one and only ...  cheers

Edited by shorterxp

Share this post

Link to post
Share on other sites
9 minutes ago, shorterxp said:

I think you mean this type of extensions...


Look in the link that was posted for command extensions.

When executing a 32-bit GUI application, CMD.EXE does not wait for the application to terminate before returning to the command prompt. This new behavior does NOT occur if executing within a command script.

Share this post

Link to post
Share on other sites

So to confirm, either use bat with wait, or just replace .bat with a identical text file (saved as .cmd) and run the .cmd from within SFX.

Alternatively to be hardcore, use both :devil:... I've yet to test. I will update to see how things work out. I still find it odd the slower machine doesn't do this.

Thanks again.

Share this post

Link to post
Share on other sites

Usual disambiguation needed.

DOS is an operating system (command line only).

It has a scripting language that uses the .bat extension for its scripts to trigger the command interpreter which is command.com

Windows 9x/Me is essentially DOS (see above) with added a GUI shell (this is intentionally simplified, let's not have the usual "no Windows 9x/Me is a full 32 bit OS" type of objection), it still uses .bat files and the command.com command interpreter.

Windows NT and later DO NOT HAVE DOS, they have a command interpreter (which is cmd.exe and not command.com) that runs script files, similar but NOT identical to DOS batches, with the .cmd extension, but also a .bat file will run in NT and later.

It is recommended in NT and later to use the .cmd extension because this way a batch file written for cmd.exe but having the .bat extension won't be accidentally run on a DOS or Windows 9x/Me system, personally I remove the association to .bat from NT systems in order to avoid the reverse.

We are talking here of COMMAND EXTENSIONS, they are a feature of the command interpreter (cmd.exe) not FILE EXTENSIONS (in Explorer).

By default AFAICR these are turned on, but they are user configurable, so it is good practice to always start a .cmd batch eith either:




in order to know for sure if locally (i.e. within the batch) they are ON or OFF.


Edited by jaclaz

Share this post

Link to post
Share on other sites

Yeah, sorry for taking long time to post as fixed.

It was indeed extensions, as you suggested, they were enabled (on by default) and was calling CSScript command twice, once  via CScript, and second ZipClose.vbs (.vbs is looked up automatically and appropriate .exe used, as is typical when extensions are on).

I just had to remove "CScript" from the line. I also made the BAT a CMD.

Code is much tidier now and all works well.

Thanks for the help!

Edited by shorterxp

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.