Re-doing a C program to run in Win2000 or XP

This is a discussion on Re-doing a C program to run in Win2000 or XP within the C Programming forums, part of the General Programming Boards category; I have a C program written years ago compiled on Microsoft C 1.5. It run in DOS. It uses an ...

  1. #1
    Registered User
    Join Date
    May 2003
    Posts
    5

    Re-doing a C program to run in Win2000 or XP

    I have a C program written years ago compiled on Microsoft C 1.5. It run in DOS. It uses an input card that is configures in the config.sys file and it start through the autoexec.bat file running on Windows 95. The computer runing the program is very crappy right now and I want to re-build it. Since its hard to buy a new computer with Win 95, how can I get the program to run the same way (using autoexec and config.sys and DOS) on either Win2000 or XP. Do I need to recompile the program in Visual Studio 6.0 or so? I am not planing to change the program itself I just want it to run on the DOS shell of a more modern OS.

  2. #2
    Dr Dipshi++ mike_g's Avatar
    Join Date
    Oct 2006
    Location
    On me hyperplane
    Posts
    1,218
    You could try running it in DOSBox.

  3. #3
    Kernel hacker
    Join Date
    Jul 2007
    Location
    Farncombe, Surrey, England
    Posts
    15,677
    If you load a driver in Config.sys, then you can't use it under Windows NT (Windows 2000 is a NT 5.0 in this respect).

    You'll need to find/create a Win2K style driver first, which may or may not be difficult, depending on what you need the driver to do.

    --
    Mats

  4. #4
    and the hat of wrongness Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    32,590
    If it's an ISA card, you might have trouble finding a machine to plug it into in the first place.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.
    I support http://www.ukip.org/ as the first necessary step to a free Europe.

  5. #5
    Registered User
    Join Date
    May 2003
    Posts
    5
    Its an ISA Card but I have a Windows 2000 box with ISA slot. I will see if the mfg of the card has a w2K driver. The other question is that will the program run as is or I have to recompile it in say Visual studio 6. The original program was compiled in C 1.5

  6. #6
    Kernel hacker
    Join Date
    Jul 2007
    Location
    Farncombe, Surrey, England
    Posts
    15,677
    It is quite unlikely that the original software will work under Win2K even if you have a driver, as the software is most likely using the DOS-mode interface, rather than the Win2K interface. So you'll need to rework the software itself - not just recompile it. But without seeing the code of the software, it's hard to say.

    --
    Mats

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Client-server system with input from separate program
    By robot-ic in forum Networking/Device Communication
    Replies: 3
    Last Post: 01-16-2009, 02:30 PM
  2. Using variables in system()
    By Afro in forum C Programming
    Replies: 8
    Last Post: 07-03-2007, 12:27 PM
  3. Need help with program
    By HAssan in forum C Programming
    Replies: 8
    Last Post: 06-10-2007, 08:05 PM
  4. Replies: 3
    Last Post: 07-11-2005, 03:07 AM
  5. Replies: 5
    Last Post: 04-17-2003, 07:07 AM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21