CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 7 of 7
  1. #1
    Join Date
    Sep 2015
    Location
    Kolkata
    Posts
    13

    How to create .com file

    I want to create a .com file. I want to know the procedure, how to make a COM (.com) file from C source code file.
    Please suggest.

  2. #2
    VictorN's Avatar
    VictorN is offline Super Moderator Power Poster
    Join Date
    Jan 2003
    Location
    Hanover Germany
    Posts
    20,396

    Re: How to create .com file

    1. What for?
    2. What OS?
    Victor Nijegorodov

  3. #3
    Join Date
    Oct 2006
    Location
    Sweden
    Posts
    3,654

    Re: How to create .com file

    First of all you have to find an ancient 16-bit compiler. I think that the old Borland Turbo C++ suites now are available for free so go ahead and search.

    Then you have to find an OS that is able to run a com-file (and also the compiler). Whithout knowing for sure I would guess that it means you have to go back to something like Windows Millenium edition or earlier. If the executable is well behaved (don't have wild accesses to hardware) it might also run in some of the more recent NT based 32 bit versions of Windows but I don't know if and if so when the support for .com ended.
    Debugging is twice as hard as writing the code in the first place.
    Therefore, if you write the code as cleverly as possible, you are, by
    definition, not smart enough to debug it.
    - Brian W. Kernighan

    To enhance your chance's of getting an answer be sure to read
    http://www.codeguru.com/forum/announ...nouncementid=6
    and http://www.codeguru.com/forum/showthread.php?t=366302 before posting

    Refresh your memory on formatting tags here
    http://www.codeguru.com/forum/misc.php?do=bbcode

    Get your free MS compiler here
    https://visualstudio.microsoft.com/vs

  4. #4
    Join Date
    Sep 2015
    Location
    Kolkata
    Posts
    13

    Re: How to create .com file

    Sir, OS- Windows 7. Sir I want to create .com file of any C Source code file.

  5. #5
    2kaud's Avatar
    2kaud is offline Super Moderator Power Poster
    Join Date
    Dec 2012
    Location
    England
    Posts
    7,824

    Re: How to create .com file

    Quote Originally Posted by Arup Kr Goswami View Post
    Sir, OS- Windows 7. Sir I want to create .com file of any C Source code file.
    The short answer is no.

    Why?
    All advice is offered in good faith only. All my code is tested (unless stated explicitly otherwise) with the latest version of Microsoft Visual Studio (using the supported features of the latest standard) and is offered as examples only - not as production quality. I cannot offer advice regarding any other c/c++ compiler/IDE or incompatibilities with VS. You are ultimately responsible for the effects of your programs and the integrity of the machines they run on. Anything I post, code snippets, advice, etc is licensed as Public Domain https://creativecommons.org/publicdomain/zero/1.0/ and can be used without reference or acknowledgement. Also note that I only provide advice and guidance via the forums - and not via private messages!

    C++23 Compiler: Microsoft VS2022 (17.6.5)

  6. #6
    Join Date
    Sep 2015
    Location
    Kolkata
    Posts
    13

    Re: How to create .com file

    Sir just to learn that how to create.

  7. #7
    Join Date
    Nov 2000
    Location
    Voronezh, Russia
    Posts
    6,620

    Re: How to create .com file

    You were just told how to create. You need a compiler that can target MS DOS. The most known are Borland C++ 3.x, MS Visual C++ 1.x, Watcom C++ something, I don't remember, 8 or 9, or maybe 10. You can try Open Watcom, maybe they still support DOS just for fun.
    Best regards,
    Igor

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured