How specify blank line in XP's DOS box?

W

WM

Of course XP's command line window is not native DOS but it is
designed to look very similar.

I have a short BAT program (see below) which shows me the values
in three registry keys. I would like to format the output from
the BAT program to look a bit tidier.

(a) I would like to know how to put blank lines in the output.

(b) I would like to remove the line
! REG.EXE VERSION 3.0

Can someone please advise. Thank you.



This is my BAT file:
------------------------ START -----------------------------
@echo off
cls
c:
cd \

REG QUERY

HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer /v

DesktopProcess

echo .

REG QUERY

HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\BrowseN

ewProcess /v BrowseNewProcess

echo .

REG QUERY

HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advance

d /v SeparateProcess

@echo off

pause
exit
------------------------ END -----------------------------
 
P

Pegasus \(MVP\)

You're right - there is no DOS under WinXP. It's usually
called the Command Prompt.

There are a few options to generate a blank output line.
Here are two of them:
echo.
echo\

About your second question - how to remove the line
reg.exe version 3.0: Difficult to say, because it is not
visible in your post and you don't say where you want
it removed from.
 
M

Marcus Houlden

Of course XP's command line window is not native DOS but it is
designed to look very similar.

I have a short BAT program (see below) which shows me the values
in three registry keys. I would like to format the output from
the BAT program to look a bit tidier.

(a) I would like to know how to put blank lines in the output.

ECHO.

not

ECHO .

mh.
 
B

billious

WM said:
Of course XP's command line window is not native DOS but it is
designed to look very similar.

I have a short BAT program (see below) which shows me the values
in three registry keys. I would like to format the output from
the BAT program to look a bit tidier.

(a) I would like to know how to put blank lines in the output.

(b) I would like to remove the line
! REG.EXE VERSION 3.0

Can someone please advise. Thank you.



This is my BAT file:
------------------------ START -----------------------------
@echo off
cls
c:
cd \

REG QUERY

HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer /v

DesktopProcess

echo .

REG QUERY

HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\BrowseN

ewProcess /v BrowseNewProcess

echo .

REG QUERY

HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Advance

d /v SeparateProcess

@echo off

pause
exit
------------------------ END -----------------------------


REG QUERY .... | find /v "! REG.EXE VERSION 3.0"

where "|" (pipe) is normally shift-\

FIND will find the string in quotes and display only lines containing that
string.
/v reverses the sense and display lines NOT containing the string.
/i AAMOI, does a case-insensitive match.

From the prompt, try

FIND /?
for documentation, or

FINDSTR /?
for a similar tool available on NT/2K/XP.

Generally,

commandname /?

will show help for the commandname

NT/2K/XP batch discussion groups include alt.msdos.batch.nt and
microsoft.public.win2000.cmdprompt.admin

HTH

....Bill
 
M

MoiMeme

To be more clear : @echo. without any space between @echo and . will issue a
blank line. If you @echo . You will echo a ., not a blank line
 
P

Plato

WM said:
Of course XP's command line window is not native DOS but it is
designed to look very similar.

I'ts just a command line window. Nothing to do with dos.
 
D

David Candy

No it's not. It's a console. All consoles look alike. It's heritage is CP/M, UNIX, and QDOS. But it looked like that on mainframes too before any of the above were invented. My text editor was a command line text editor (full screen not like edlin). One would type at the prompt

r dog cat

to replace all strings dog with cat.

Why are you writing this anyway?
 
W

WM

No it's not. It's a console. All consoles look alike. It's
heritage is CP/M, UNIX, and QDOS. But it looked like that on
mainframes too before any of the above were invented. My text
editor was a command line text editor (full screen not like
edlin). One would type at the prompt

r dog cat

to replace all strings dog with cat.

Why are you writing this anyway?


I run XP Pro/SP2. My Win Explorer locks up too frequently. To
get out of a lock, I use Task Manager to kill the process and
restart Explorer. Messy but can't find another way.

I'm setting and unsetting registry keys for DesktopProcess,
SeparateProcess and BrowseNewProcess to try and get better
stability.

The little program queries the registry for these keys to show me
what I have got set.

But it's quite hard to get a combination of settings which give
good stability.
 
D

David Candy

If you have memory set them all and neber think about it again. What they do is limit what is taken down in a crash. They don't prevent crashes.
 
M

Marcus Houlden

I run XP Pro/SP2. My Win Explorer locks up too frequently. To
get out of a lock, I use Task Manager to kill the process and
restart Explorer. Messy but can't find another way.

I'm setting and unsetting registry keys for DesktopProcess,
SeparateProcess and BrowseNewProcess to try and get better
stability.

Sounds like it might be better to fix the underlying problem than to fiddle
about with the registry. Check for dodgy drivers or consider a reinstall.
Explorer might be unstable but how do you know that isn't a symptom of a
problem somewhere else?


mh.
 
W

WM

Why are you writing this [bat file] anyway?

I run XP Pro/SP2. My Win Explorer locks up too frequently. To
get out of a lock, I use Task Manager to kill the process and
restart Explorer. Messy but can't find another way.

I'm setting and unsetting registry keys for DesktopProcess,
SeparateProcess and BrowseNewProcess to try and get better
stability.

The little program queries the registry for these keys to show
me what I have got set.

But it's quite hard to get a combination of settings which give
good stability.


If you have memory set them all and neber think about it again.
What they do is limit what is taken down in a crash. They don't
prevent crashes.


I have 768 MB memory but I still get problems when I enable all of
these: DesktopProcess, SeparateProcess, BrowseNewProcess.
If all are set on then my PC seems more likely to lock or just go
into delays more than usual (I'm running a 2200 MHz).

Is it likely that memory is causing my Explorer locks or are they
likely to be due to something else? Maybe the following observation
can provide a clues? ...

When I set XP to have more than one process then I might see several
entries for "Explorer" in Task Manager. If things go wrong then I
might find that a hotkey will not launch an application. So
sometimes killing just the Explorer processes lower down the list can
free something up and permit the application to launch.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top