2 Replies - 370 Views - Last Post: 28 February 2011 - 12:03 PM Rate Topic: -----

#1 Fightxp  Icon User is offline

  • New D.I.C Head

Reputation: -3
  • View blog
  • Posts: 17
  • Joined: 28-February 11

C++ file executing question!

Posted 28 February 2011 - 11:42 AM

Hello, a question for C++ file execution.
wondering how to save the code as executable file running in DOS prompt or linux system.
As far as I run the output, it can be normally running in window system.
But if running in cmd mode, it'd say that "it is not recongised as a n internal or external command, operable program or batch file.". Guess that file does not provide sort of registry data for itself.
I wanna the file saved as well as an application. Pls, anyone shares some tips. THX

I m programming C++ complied by visual studio 2010 express.

This post has been edited by Fightxp: 28 February 2011 - 11:52 AM


Is This A Good Question/Topic? 0
  • +

Replies To: C++ file executing question!

#2 Martyn.Rae  Icon User is offline

  • The programming dinosaur
  • member icon

Reputation: 540
  • View blog
  • Posts: 1,406
  • Joined: 22-August 09

Re: C++ file executing question!

Posted 28 February 2011 - 11:51 AM

This is a very confusing post, but I will try and respond to it based on what I understand.

A program that runs from a Microsoft DOS command prompt is not transferable to a Linux system terminal prompt (without recompiling th source code to obtain a LINUX compatible executable).

A program that was written as a 16-bit executable is not supported by Microsoft Windows unless you use a 16-bit emulator (I believe DOSBOX is such an emulator).

Hope that helps.
Was This Post Helpful? 0
  • +
  • -

#3 Fightxp  Icon User is offline

  • New D.I.C Head

Reputation: -3
  • View blog
  • Posts: 17
  • Joined: 28-February 11

Re: C++ file executing question!

Posted 28 February 2011 - 12:03 PM

View PostMartyn.Rae, on 28 February 2011 - 11:51 AM, said:

This is a very confusing post, but I will try and respond to it based on what I understand.

A program that runs from a Microsoft DOS command prompt is not transferable to a Linux system terminal prompt (without recompiling th source code to obtain a LINUX compatible executable).

A program that was written as a 16-bit executable is not supported by Microsoft Windows unless you use a 16-bit emulator (I believe DOSBOX is such an emulator).

Hope that helps.


YA! good reminding.

too vague to express my saying. I put the question onto how to save C++ file as exe type running in DOS Prompt. I simply catch the exe file from debug's folder and run. It is working under windows system.
However, if running in pure dos system, it shows the words as de above post.


thx.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1