Contact US

Log In

Come Join Us!

Are you an
Engineering professional?
Join Eng-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

console app in visual fortran 6.5

console app in visual fortran 6.5

console app in visual fortran 6.5

I have an old program using Escape sequences for userinteraction on a screenbasis. It has bene working on many different systems and all those escapesequences are generated in ONE routine working on the definition of what has to be shown.

Now (after over 10 years) I need to make that program run under XP . I tried loading ANSI.SYS and some 'solutions' i found on the web but no succes.

So I think best thing to do now is to rewrite that routine that's actually displaying the escapesequences (I've done that in the past for a number of systems so that's not a big deal as such) and use 'something else'.

I just 'played' a bit trying to get a consolewindow . I can position cursor and write something, but i still don't know how to read a KEY, how to use color and such things.
So i wonder if a good example exists showing how such things can be done.
I also don't know if a another approach (NOT using a consolewindow) wouldn't be suited more.
As I expect others to have experience with such a conversion I would appreciate any help.

It's OK to me if I need/can use C++ / C# or VB to 'assist' in creating those (interactive) screens

thanks in advance

RE: console app in visual fortran 6.5

You can use ANSI.sys but it has to be from command.com: not cmd.exe.  This means that everything runs as 16-bit.  When it crashes, it is quite spectacular: it takes down all the 16 bit programs with it.

Alternatively, have a look for ansicon on the net.  The website keeps on moving.

Which compiler are you using?  The current version of g95 doesn't seem to translate the ANSI sequences correctly.  It worked on g95 3 years ago.  Don't know about gfortran.

Another alternative is to use Silverfrost - it will do the windows type things: same as what you would do in C++/VB but you don't have to learn a new language and all its idiosyncracies.

RE: console app in visual fortran 6.5

Sorry - just noticed you were using CVF. You can access screen addressing using the win32 calls if you're using CVF.

RE: console app in visual fortran 6.5

thanks for the info, I'll go through them.

a) I will try command.com, but I'm not sure if I cna use it. I still have the version using FTN77 with DBOS. (Salford --> Silverfrost). If THAT would be possible all would run at once without doing ANYTHING. But I'm afraid that won't work as FTN77 used 32 bits.
Of course I will try CVF with it as well.
(I will do both next week as I have a LOT of things to do this week)

b) I had a look at Ansicon before, but I couldn't get it running with my software (I also tried a program called DosBox).

c) I'm considering Silverfrost FTN95


RE: console app in visual fortran 6.5

Siverfrost have a FREE version of FTN95 for personal use, this SHOULD compile your FTN77 code with minimal (or may be no) changes.

RE: console app in visual fortran 6.5

You can run 32 bit programs on command.com - this uses config.nt and autoexec.nt - the dos equivalents of config.sys and autoexec.bat.

RE: console app in visual fortran 6.5

Does VB work with Dos box windows?  Hmmm.  I know QuickBasic does (from which VB sprang).

From my past experience with QB,  it is an excellent language for simple Dos screen manipulations (with color).  And, since you are already a fortran programmer, picking up the little bit of QB you need for the task would be a breeze.

Dan   smile

RE: console app in visual fortran 6.5

Depends which version of VB.  Basically, you need to use the VB equivalent of SetConsoleCursorPosition.

VB6 is a bit of a frig but you can get it to do console programs.

VB.net can do console programs.

VBScript can also do console programs but cursor addressing can be difficult.

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members! Already a Member? Login


Low-Volume Rapid Injection Molding With 3D Printed Molds
Learn methods and guidelines for using stereolithography (SLA) 3D printed molds in the injection molding process to lower costs and lead time. Discover how this hybrid manufacturing process enables on-demand mold fabrication to quickly produce small batches of thermoplastic parts. Download Now
Design for Additive Manufacturing (DfAM)
Examine how the principles of DfAM upend many of the long-standing rules around manufacturability - allowing engineers and designers to place a part’s function at the center of their design considerations. Download Now
Taking Control of Engineering Documents
This ebook covers tips for creating and managing workflows, security best practices and protection of intellectual property, Cloud vs. on-premise software solutions, CAD file management, compliance, and more. Download Now

Close Box

Join Eng-Tips® Today!

Join your peers on the Internet's largest technical engineering professional community.
It's easy to join and it's free.

Here's Why Members Love Eng-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close