Richard,
Not a valid win32
applicationhttp://
www.computerhope.com/issues/ch000726.htm
Did you do an Advanced Search for cmd.* to find every possible file? The
PATHEXT variable is the order that extensions are searched when you do
not
type one, .com comes before .exe.
There should be two cmd.exes on your machine and not any other cmd.*
files
with any other extension.
%systemroot%\system32\cmd.exe, the one that gets used.
%systemroot%\system32\dllcache\cmd.exe, backup for Windows File
Protection.
%systemroot%\ServicePackFiles\i386\cmd.exe, if a ServicePackFiles folder
exists the i386 folder is used for WFP instead of the dllcache folder.
Not
all XP installations even have a ServicePackFiles folder, neither of mine
do.
What does Start | Run | cmd.com produce? Windows cannot find 'cmd.com'
would be a good result.
You stated that: %SystemRoot%\system32\cmd.exe works fine.
Does %SystemRoot% = F:\WINXPPRO?
Does %SystemRoot% typed into Start | Run open F:\WINXPPRO?
Does F:\WINXPPRO\system32\cmd.exe typed into Start | Run work?
I just created a bogus cmd.exe in C:\WINDOWS. I created a 0 byte .txt
file
and renamed it to cmd.exe. Start | Run | cmd still works OK because
system32 is in the path before the WINDOWS folder is. That is, the
system32
folder is searched before the WINDOWS folder.
However, C:\WINDOWS\cmd.exe in the Run command gets this error:
---------------------------
C:\WINDOWS\cmd.exe
---------------------------
C:\WINDOWS\cmd.exe is not a valid Win32 application.
---------------------------
OK
---------------------------
Your PATH may still somehow be messed up.
Why don't my commands
work?
http://internet.cybermesa.com/~bstewart/cmdprompt.html#6
Run the System File Checker. System File Checker (sfc.exe) replaces
screwed
up system files.
Load your XP CD in your CD drive.
Start | Run | Type or paste: sfc /scannow | Click OK
sfc /scannow scans all protected system files immediately and replaces
incorrect versions with correct Microsoft versions.
System File Checker takes a while to run.
If you have XP Home and it asks for your XP Pro CD, see this KB
article...
You may be prompted to insert a Windows XP Professional CD when you run
the
System File Checker tool in Windows XP Home
Editionhttp://support.microsoft.com/kb/897128
If SFC.EXE did anything it will be listed in the Event Viewer.
Open the Event Viewer...
Start | Run | Type: eventvwr | Click OK | Click System |
Windows File Protection will be listed under the Source column. Look at
any
Windows File Protection entries.
Explains a whole bunch about sfc.exe.
scannow sfc (sfc.exe)
http://www.updatexp.com/scannow-sfc.html
Description of Windows XP and Windows Server 2003 System File Checker
(Sfc.exe)
http://support.microsoft.com/kb/310747
--
Hope this helps. Let us know.
Wes
MS-MVP Windows Shell/User
InRichard <
[email protected]> hunted and pecked:
Hi Wes,
PATHEXT=.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH
Here's mine:
.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.RB;.RBW
I merely added on two extensions for Ruby some time ago.
UPDATE your antivirus software and run a full system scan.
Did that with AVG-Free; it found and disabled Trojan horse Downloader-
Agent.KNW
I didn't notice your protected-mode suggestion; I'll rerun in P.M.
tonight.
I'm still working on the other suggestions.
Thanks for your guidance, Wes. It's much appreciated.
Best wishes,
Richard
PATHEXT=.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH
--
Hope this helps. Let us know.
Wes
MS-MVP Windows Shell/User
InRichard <
[email protected]> hunted and
pecked:
Hi y'all,
Thanks for the (great) replies.
So far:
There are no apparently related errors in Event Viewer
I'm writing a Ruby script to search the top-level entries in each dir
on the path for cmd.[bat,com,exe], case ignored. I already discovered
3 no-longer-valid directories so far, and excised them.
I'll report back in a day or two with new discoveries or questions.
I've got to go play with my grand-children now. That takes
precedence
Best wishes,
Richard
On May 4, 11:49 pm, Richard
Hi All,
I'm having trouble connecting to my ISP's home page on my WinXP-Pro/
SP2 system using both IE7 and Firefox. Both of them go into infinite
loops trying to bring up the home page.
BTW, my Win2003/SP1 server display the ISP's home page perfectly
(while connected to the same router and ultimately the same cable
modem as the workstation.)
I had ISP's tech support trying to resolve the problem. In the
course of doing that, he asked me to bring up a Command window by
entering CMD in the Start | Run textbox and press Enter. XP
reported "cmd is not a valid Win32 application".
I want to find out why this error is raised because it may provide a
clue as to the problem I described at the top of this msg. Here's
what I know:
Start | Run for
-- cmd.exe (i.e., with the .exe extension) fails in the same way.
-- %SystemRoot%\system32\cmd.exe works fine.
That made me think the Path was at fault. But ...
--- the path contains the string ;F:\WINXPPRO\system32; in the
middle, which looks right
--- the commands cmd and chkdsk work fine in a Command window, even
when the CWD is focused on a drive other than %HOMEDRIVE%
Does anyone have any idea what I do to identify what prevent cmd.exe
from being executed from Start | Run?
TIA,
Richard