For Programmers: Free Programming Magazines  


Home > Archive > Fortran > September 2006 > DOS Extended Fortran Problems









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author DOS Extended Fortran Problems
Jim Klein

2006-09-25, 7:00 pm

Hi,

I have some old DOS extended 32 bit programs that ran in the DOS
Window. On Win 2000 the DOS box opens and closes and automatically
shuts down the program.

Why ?

Is there a work around ?

Jim
James E. Klein
jameseklein@earthlink.net

Engineering Calculations
http://www.ecalculations.com
ecalculations@ecalculations.com
Engineering Calculations is the home of
the KDP-2 Optical Design Program
for Windows and (soon) MAC OSX
Free KDP-2 (DEMO) downloadable!
1-818-507-5706 (Voice and Fax)
Berend Hasselman

2006-09-25, 7:00 pm

Jim Klein wrote:
> Hi,
>
> I have some old DOS extended 32 bit programs that ran in the DOS
> Window. On Win 2000 the DOS box opens and closes and automatically
> shuts down the program.
>
> Why ?
>


I don't exactly know.
There is a problem with running old programs that use a Dos extender under Windows 2000 and XP.

They won't run.
I remember that there was a remark on this problem somewhere on the Microsoft site.
I haven't been able to find it. The advice was: recompile.

My (our) solution in the past was: recompile with newest Fortran compiler (in our case Lahey).


> Is there a work around ?
>


Not As far as I know.

Berend Hasselman

> Jim
> James E. Klein
> jameseklein@earthlink.net
>
> Engineering Calculations
> http://www.ecalculations.com
> ecalculations@ecalculations.com
> Engineering Calculations is the home of
> the KDP-2 Optical Design Program
> for Windows and (soon) MAC OSX
> Free KDP-2 (DEMO) downloadable!
> 1-818-507-5706 (Voice and Fax)

e p chandler

2006-09-25, 7:00 pm

Jim Klein wrote:
> Hi,
>
> I have some old DOS extended 32 bit programs that ran in the DOS
> Window. On Win 2000 the DOS box opens and closes and automatically
> shuts down the program.
>
> Why ?
>
> Is there a work around ?
>


Here are a few things to try.

1. Right click on the program icon. Select Properties then
Compatibility, then try one of the options.

2. Execute COMMAND.COM first then from inside this shell try again.

3. see http://dosbox.sourceforge.net/news.php?show_news=1
for DOSBOX, a DOS emulator

4. Several dos extenders are known not to work with XP (or 2000) - MS
Fortran Powerstation 1.00 (old PharLap TNT), F77l-EM/32, Salford DBOS,
ELF90 v2 & v3.
You may be able to find at auction or purchase a newer version of TNT.

5. Recompile. Easy upgrade paths for

MS -> CVF/IVF
Lahey
Watcom -> Open Watcom
Salford -> FTN77 & FTN95

-- e-mail: epc8 at juno dot com
-- Elliot

Terence

2006-09-25, 7:00 pm

I know of one problem that gives this description of what is happening.
It might not be the cause, but this situation happens only on W2000, NT
and XP machines if they have ever been updated on-line. A virgin W2000
would run normally; XP I'm not sure about.

Windows now takes part of the DOS stack for security purposes. This
can cause a "Stack Overflow 2000 message" in MSDOS executions, which
may not survive on the screen long enough to be seen before DOS quits.

This problem is solved by uing the program EXEMOD.exe to increase the
stack size by an extra 4000 hex bytes.
Note: EXEMOD.exe itself has ALSO to be ALSO extended in its stack the
same way (use a W95 or W98 machine to do this, or ask me to send a
zipped, extended version exemod2.exe).

The actual stack size is in bytes 17,18 of the DOS program, as low
-high bytes (usually #8000)

Exemod.exe usage:

EXEMOD filename.exe /stack hhhh (hex value, try original+0400)

Use fm.com or FMNT.exe or a binary editor to show actual stack size and
add 4k to the number.

Stack is in 17-18 as low-high (use hhhh as 000C = #0c00 for new stack)


YOU NEED THIS CHANGE IN ANYTHING THAT USES SYSTEM OR SPAWN!!

usage: EXEMOD filename.exe [-/h] [-/stack nnnn] [-/max] [-/min]

meek@skyway.usask.ca

2006-09-25, 7:00 pm

In a previous article, Jim Klein <jameseklein@earthlink.net> wrote:
>Hi,
>
>I have some old DOS extended 32 bit programs that ran in the DOS
>Window. On Win 2000 the DOS box opens and closes and automatically
>shuts down the program.
>
>Why ?
>

AFAIK there's a way to keep the dos window open after the
program stops ... but usually I go into "DOS" (or "command line"
on XP ) and run it from there.
Then you can see the message.
Chris
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com