Yahoo Answers is shutting down on May 4th, 2021 (Eastern Time) and beginning April 20th, 2021 (Eastern Time) the Yahoo Answers website will be in read-only mode. There will be no changes to other Yahoo properties or services, or your Yahoo account. You can find more information about the Yahoo Answers shutdown and how to download your data on this help page.
Trending News
Write MSDOS com program using dotnet (console)?
I have a job where old MSDOS 6.2 x86 machines are being used to communicate with external hardware via RS232. Long story short their MIS department is +20 years behind the current state of the art. Basically they look at these old MSDOS machines as free PC's no one else wants which function well enough for task at hand. (basically as simple user interface / display devices for their black boxes)
How can i write a simple console program using Vb2010 that will run in a WIN16 MSDOS 6.2 OS environment?
I know that I could use QBASIC but it has been decades since i used it and i would rather use current development environments i have on my own pc rather than use dinosaur PC's at work.
I hope to be able to drag these guys into the 21st century and get them off of sneaker net and show them the advantages of networked PC's for data logging. Etc... These guys even make a number of employees share a single networked PC And share a single email account between them all!
5 Answers
- RatchetrLv 79 years ago
The oldest supported OS for .NET is Windows 98.
Are these machines really so old Win98 isn't an option? (Of course, they would need to get a valid Win98 license as well, which isn't free). But I would think you could find some nearly free boxes with Win98 already installed for not too much money. Just tell the IT guys to spend their weekends visiting garage sales ;-)
If that isn't an option, you'll probably be stuck doing this in C or C++. And you will need to find a 16-bit compiler. Not many of those left. Turbo C, MSVC 1.6, OpenWatcom (link).
But yeah, those are fairly primitive tools by today's standards.
If you code carefully, you might be able to write and debug most of the app as a Win32 Console application, then recompile using a 16-bit compiler for the final output. You would need to wrap all the serial IO and probably a few other things inside a library or set of wrapper functions, and have 2 versions of those functions, since serial IO is very different in Windows vs. DOS.
And you may run into timing issues where things work fine on a real machine, but fail on an ancient box due to it being slower.
Not a fun situation.
- peteamsLv 79 years ago
Unfortunately I don't believe its possible to get a .NET application to run on a DOS machine.
In order to execute a .NET application you need the .NET Framework installed. These exist for "modern" computers like 32-bit and 64-bit Windows, Windows Phone, Xbox and other platforms from the last decade.
I do not believe there is an implementation of the framework for the 16-bit world. You might be lucky and find someone has implemented a Java Virtual Machine for DOS, but I expect it's doubtful.
- mmarreroLv 69 years ago
DOS serial apps ran better than native Windows 3.x apps, and ran well in Windows 9x/Me. That's probably why they haven't migrated..
VB.NET is a wonderful environment, but it's incredibly incompatible with legacy code. Even the VB6 converter in older .NET could barely convert a Hello World! VB6 program...
You can try Linux which should have good DOS support. There's also DOSBox for Windows, but I don't know how well it emulates serial ports.
You can also stay in DOS, using FreeDos. Avoiding QB, FreePascal should be similar to Turbo Pascal 6/7, which was extremely popular because because of its inline assembly language support.
The only good thing about DOS is that it feels like programming a microcontroller. 20 years ago I wrote in Turbo C 2.0 and MASM a serial app, via the 8250 chip, and my own IRQ handler, rather than using truly mediocre BIOS and DOS calls. (I also wrote my text routines and a Messagebox/menu functions in C.)
Btw, almost all network cards have NDIS drivers which also work on DOS! Only problem is the protocol, I wonder if there's SAMBA or NFS for DOS.
- DynaSoarLv 49 years ago
PowerBASIC still offers a DOS compiler. Pretty much like an extended QBasic/QuickBasic which is OK with 32bit Windows systems even WinVista-32 and Win7-32. There is a free demo to download (the /pbdos/ link) and see what it can do.
You might want to check it out here.
- How do you think about the answers? You can sign in to vote the answer.
- 9 years ago
I don't think you can even Put lipstick on That pig :-)
or
C:\Users\perry>lipstick
'lipstick' is not applicable as an internal or external help, fix, or pig changer.