16-bit under WinXP Pro?

  • Thread starter Thread starter Per Odegaard
  • Start date Start date
P

Per Odegaard

Is there a way of stopping DOS windows popping up on the Desktop when
starting/stopping 16-bit programmes (from a BAT file)?

Regards,
Per Odegaard.
 
I don't know who this is from, but "" works.

[[I have found that if you use start with "" command_to_execute.exe it
kills the batch file window off right away.

e.g

@echo off
start "" calc.exe

will start calc.exe and kill of the command prompt where as

@echo off
calc.exe

will not.]]

Found it.

Morgan
http://www.ureader.com/message/773841.aspx

--
Hope this helps. Let us know.

Wes
MS-MVP Windows Shell/User

In
 
Thanks, Wes!
I've tried it out, but it doesn't work here.
My problem with the batch file windows is that my monitor blackens
when they appear, forcing me to reboot.
I've found a way to avoid this: If I right-click on the desktop immediately
after starting the (16-bit) programme, which throws up a help window
("Arrange Icons By" etc), the batch file window will not open, and
everything is fine.

Regards,
Per Odegaard.
________________________________________________________

I don't know who this is from, but "" works.

[[I have found that if you use start with "" command_to_execute.exe it
kills the batch file window off right away.

e.g

@echo off
start "" calc.exe

will start calc.exe and kill of the command prompt where as

@echo off
calc.exe

will not.]]

Found it.

Morgan
http://www.ureader.com/message/773841.aspx

--
Hope this helps. Let us know.

Wes
MS-MVP Windows Shell/User

In
 
My BAT file contains several lines with

@echo off

Should the new line

start "" calc.exe

be added after each one?

Regards,
Per.
 
Per,

Why don't you post the contents of your batch file here. I'm sure that
someone will post helpful advice. Without knowing what you have, it would
all be guesswork.

You only need one @echo off if you are not including any echo on commands.
You only need to turn off echo once if you're not turning it on again.

From Echo help...
• The echo message command is useful when echo is turned off. To display a
message that is several lines long without displaying other commands, you
can include several echo message commands after the echo off command in your
batch program.
• If you use echo off, the command prompt does not appear on your screen. To
display the command prompt, type echo on.
•To prevent echoing of a line, insert an at sign (@) in front of a command
in a batch program.

--
Hope this helps. Let us know.

Wes
MS-MVP Windows Shell/User

In
 
Hi again.

This is what my BAT file (called RUNFBB.BAT) looks like:

@echo off
break off
set fbb=\FBB
goto %1

:start ********************** START script begins ************************
@echo off
: The following two lines previously inserted to try to overcome my
problems:
: cd \windows\prefetch
: del ntvdm.*
:
cd %fbb%
goto end
rem *************************** START script ends ***********************

:rerun *********************** RERUN script begins ************************
@echo off
cd %fbb%
goto end
rem *********************** RERUN script ends*******************

:maint ***************** MAINT script begins **********************
@echo off
cls
echo Housekeeping in message database...
cd %fbb%
del epurmess.res
epurmess
rem EPURWP only applies when using White Pages...
rem Parameters: Number of days before updating, and before deleting
REM EPURWP 14 365 reduced to 14 180 on 19/11/99
epurwp.exe 14 180
del %fbb%\system\wp\wp.old
cd c:\fbb\bin
strus.exe
cd c:\fbb
report.exe
cd %fbb%\system
copy c:\fbb\system\dirmes.sys c:\fbb\backup\dirmes.old
copy c:\fbb\system\inf.sys c:\fbb\backup\inf.old
clr_user>>%fbb%\clr_user.res
MAINTINF 3 /a
COPY %FBB%\SYSTEM\INF.NEW %FBB%\SYSTEM\INF.SYS
cd %fbb%
REM 15/7/05 del %fbb%\system\dirmes.new
REM 15/7/05 del %fbb%\system\dirmes.old
:direct
goto end
rem ************************ MAINT script ends *********************


:stop ********************** STOP script begins ***********************
goto end
rem ************************** STOP script ends *********************


:error ********************** ERROR script begins *********************
echo WFBB exited with ERRORLEVEL %2
@echo off
sleep 5
goto end
rem *********************** ERROR script ends **********************

:end
echo %1 script is finished.
@echo off
sleep 2
exit
___________________________________________________________

If anybody out there have any suggestions as to how to avoid DOS windows on
my desktop, I'd be very pleased.

Regards,
Per.
___________________________________________________________

Per,

Why don't you post the contents of your batch file here. I'm sure that
someone will post helpful advice. Without knowing what you have, it would
all be guesswork.

You only need one @echo off if you are not including any echo on commands.
You only need to turn off echo once if you're not turning it on again.

From Echo help...
.. The echo message command is useful when echo is turned off. To display a
message that is several lines long without displaying other commands, you
can include several echo message commands after the echo off command in your
batch program.
.. If you use echo off, the command prompt does not appear on your screen. To
display the command prompt, type echo on.
..To prevent echoing of a line, insert an at sign (@) in front of a command
in a batch program.

--
Hope this helps. Let us know.

Wes
MS-MVP Windows Shell/User

In
 
Hi Per,

Your best bet is to post here...

microsoft.public.win2000.cmdprompt.admin

Lots of batch file experts there.

Some of this is beyond me, but here is what I do know.

@echo off
break off
[[C:\>break /?
Sets or Clears Extended CTRL+C checking on DOS system

This is present for Compatibility with DOS systems. It has no effect
under Windows XP.

If Command Extensions are enabled, and running on the Windows XP
platform, then the BREAK command will enter a hard coded breakpoint
if being debugged by a debugger.]]
start ********************** START script begins ************************ @echo off
The following two lines previously inserted to try to overcome my problems:
cd \windows\prefetch
del ntvdm.*

Get rid of the above line. Simple explanation: the listing for ntvdm.exe in
prefetch only shows that ntvdm.exe has run at some point. Better
explanation below for prefetch.

ntvdm.exe and wowexec.exe run every time a 16-bit program runs. SWAG:
epurwp.exe, strus.exe and report.exe are 16-bit.

If command.com ever runs then ntvdm.exe will run.

Try this.

Open command.com...
Start | Run | Type: command | Click OK |
Open the Task Manager, Ctrl + Shift + Esc | Click the Applications tab |
Right click MS-DOS Prompt | Select: Go To Process |
The Processes tab will open with ntvdm.exe highlighted

wowexec.exe is used in conjunction with ntvdm.exe to run old
16-bit applications.

[[MS-DOS and 16-bit Windows programs actually run as a Win32 process. The
program that creates the virtual MS-DOS environments for these to run in
(NTVDM.EXE) is a Win32 program. A virtual DOS machine (VDM) is created for
the program, so it thinks that it is running on a machine by itself.
However, the virtual machine is a normal 32-bit Windows NT process and is
subject to the same rules of preemptive multitasking as is other programs.
However, this only applies to MS-DOS programs. ]]

[[To run 16-bit Windows applications, NT uses a VDM that contains an extra
software layer called the Win16 on Win32 (WOW) layer. Although the VDM for
Windows shares some of the code for MS-DOS VDM, all Windows applications
share the same VDM. The reason this is done is to simulate the environment
that 16-bit Windows applications run in. Because Windows applications might
want to communicate with one another, a single VDM is used. Each 16-bit
application runs as a thread of the VDM; however, the WOW layers ensures
that only one of these threads is running at any given time. ]]
http://www.microsoft.com/technet/prodtechnol/winntas/evaluate/featfunc/windowsn.mspx#ETAA

Prefetch explanation...

[[Windows XP Professional monitors the files that are used when the computer
starts and when you start applications. By monitoring these files, Windows
XP Professional can prefetch them. Prefetching data is the process whereby
data that is expected to be requested is read ahead into the cache.
Prefetching boot files and applications decreases the time needed to start
Windows XP Professional and start applications.

Prefetching is further improved if the files are located next to each other
on the outer edge of the disk. Windows XP Professional optimizes the
location of boot files and applications when the computer is idle. The
optimization occurs in the background and lasts only a minute or two; you
might hear the hard disk being accessed when optimization occurs. After the
initial optimization takes place, subsequent optimization occurs, at most,
every three days.

When you run the Disk Defragmenter tools that are included with Windows XP
Professional, they can perform any optimization updates that are scheduled
to take place during the next idle period. The Disk Defragmenter tools do
not disturb the existing layout of optimized boot files and applications.

Note
Computers running Windows XP Home Edition also prefetch and optimize boot
files and applications.]]
Optimizing Startup Times by Using Defragmentation Tools
http://www.microsoft.com/resources/documentation/Windows/XP/all/reskit/en-us/prkd_tro_uutk.asp

--
Hope this helps. Let us know.

Wes
MS-MVP Windows Shell/User

In
 
Hello, and thanks for the response.
____________________________

Your best bet is to post here...

microsoft.public.win2000.cmdprompt.admin

Lots of batch file experts there.
____________________________

I've done that now.
____________________________

Some of this is beyond me, but here is what I do know.

@echo off
break off
[[C:\>break /?
Sets or Clears Extended CTRL+C checking on DOS system
____________________________

Do you mean that I should put "c:\break /?" in the BAT file?
____________________________
start ********************** START script begins ************************ @echo off
The following two lines previously inserted to try to overcome my
problems:
cd \windows\prefetch
del ntvdm.*

Get rid of the above line. Simple explanation: the listing for ntvdm.exe in
prefetch only shows that ntvdm.exe has run at some point. Better
explanation below for prefetch.
___________________________________

The two lines were REMmed so they were inactive.
___________________________________

Try this.

Open command.com...
Start | Run | Type: command | Click OK |
Open the Task Manager, Ctrl + Shift + Esc | Click the Applications tab |
Right click MS-DOS Prompt | Select: Go To Process |
The Processes tab will open with ntvdm.exe highlighted
___________________________________

After typing command and clicking OK the screen goes black.

After rebooting I opened the Task Manager and there was no mention of MS-DOS
prompt, nor possible to select Go To Process...

Cheers,
Per.
 
____________________________

I've done that now.
____________________________

I saw it and the response.
____________________________

Do you mean that I should put "c:\break /?" in the BAT file?
____________________________

No, that was the HELP for the break command.

Open a command prompt...
Start | Run Type: cmd | Click OK |
In the command window, type:

break /?

Hit your Enter key.
___________________________________

After typing command and clicking OK the screen goes black.

After rebooting I opened the Task Manager and there was no mention of MS-DOS
prompt, nor possible to select Go To Process...
___________________________________


command.com would not stays running after rebooting.

What happened when you opened cmd.exe from typing cmd in Start | Run?

Update your antivirus software and run a full system scan.

Do the same for whatever anti-spyware applications that you have.

--
Hope this helps. Let us know.

Wes
MS-MVP Windows Shell/User

In
Per Odegaard said:
Hello, and thanks for the response.
____________________________

Your best bet is to post here...

microsoft.public.win2000.cmdprompt.admin

Lots of batch file experts there.
____________________________

I've done that now.
____________________________

Some of this is beyond me, but here is what I do know.

@echo off
break off
[[C:\>break /?
Sets or Clears Extended CTRL+C checking on DOS system
____________________________

Do you mean that I should put "c:\break /?" in the BAT file?
____________________________
start ********************** START script begins
************************ @echo off The following two lines previously
inserted to try to overcome my problems:
cd \windows\prefetch
del ntvdm.*

Get rid of the above line. Simple explanation: the listing for ntvdm.exe
in prefetch only shows that ntvdm.exe has run at some point. Better
explanation below for prefetch.
___________________________________

The two lines were REMmed so they were inactive.
___________________________________

Try this.

Open command.com...
Start | Run | Type: command | Click OK |
Open the Task Manager, Ctrl + Shift + Esc | Click the Applications tab |
Right click MS-DOS Prompt | Select: Go To Process |
The Processes tab will open with ntvdm.exe highlighted
___________________________________

After typing command and clicking OK the screen goes black.

After rebooting I opened the Task Manager and there was no mention of
MS-DOS prompt, nor possible to select Go To Process...

Cheers,
Per.
 
command.com would not stays running after rebooting.
What happened when you opened cmd.exe from typing cmd in Start | Run?

Up popped a small black (DOS?) window saying:

C:\Documents and Settings\Per Odegaard>
Update your antivirus software and run a full system scan.
Do the same for whatever anti-spyware applications that you have.

All done on a regular basis.

Per.
 

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

Similar Threads

16-bit under WinXP Pro? 14
16-bit prog problems 2
16-bit trouble? 1
It takes time... 3
WinXP & IE7 5
ServicePackFiles\i386? 4
Remote Connection -- Only 16 Bit Color 0
using ansi.sys in a *.bat file 1

Back
Top