Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re: why doesn't my system('cls') work?

by bibo (Pilgrim)
on Oct 06, 2004 at 17:09 UTC ( #397095=note: print w/replies, xml ) Need Help??


in reply to why doesn't my system('cls') work?

Well, right off the bat, there is no program named cls.com or cls.exe out there. It's a command built into the shell, cmd.exe.

--bibo

UPDATE

My point is this: system and spawn and fork and their tickish brethern will launch a new process. Those new command windows could clean their own screens with cls, but you cannot clear the screen of the currently running command window by starting a new process.

is this helping?

Replies are listed 'Best First'.
Re^2: why doesn't my system('cls') work?
by Anonymous Monk on Oct 06, 2004 at 18:48 UTC
    Just for the record, system 'cls'; does clear the screen on a sane Win(NT|2K|XP) installation.
Re^2: why doesn't my system('cls') work?
by LanceDeeply (Chaplain) on Oct 06, 2004 at 17:17 UTC
    might want to check that.
    the following outupt is from win xp
    C:\WINDOWS>dir cmd.exe /s Volume in drive C has no label. Volume Serial Number is 3833-835E Directory of C:\WINDOWS\system32 08/23/2001 04:00 AM 375,808 cmd.exe 1 File(s) 375,808 bytes
    you may wany to double check your %PATH% and make sure the directory that contains your cmd.exe is in it.

    -HTH
      The poster stipulated there was no cls command... not no cmd command.
        sorry for misreading that, but we did fix OP's %PATH% problem.
        I concur with your analysis.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://397095]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (6)
As of 2022-05-23 12:09 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Do you prefer to work remotely?



    Results (82 votes). Check out past polls.

    Notices?