• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Jeanne Boyarsky
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Frits Walraven
Bartenders:
  • Piet Souris
  • Himai Minh

Diff between execution from IDE and double clicking on the exe file?

 
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all,
I didnt know where to post my question so I came here. I work in VC++. Can anybody tell me what is the difference between executing from IDE i.e by clicking Execute abc.exe from the IDE and double clicking the exe file generated in the debug/release directory? I am getting different results by executing the exe in these two ways..and there is no way to figure out whats wrong with this.
I am sure somebody must be there in this friendliest world of Java who will answer my VC question...please help
Thanks
 
Ranch Hand
Posts: 1871
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The integrated environment allows us to run the program from within Visual C++. The system will execute your program. An MS-DOS Prompt window (as opposed to a window in the Visual C++ system) will pop up and will display any output and accept any input for your program.

When your program finishes executing, it will ask you to press any key before exiting. When you press a key, the MS-DOS Prompt window will disappear. (The code for this is added automatically by Visual C++ when running under the IDE. It does not appear if you run the program explicitly in a stand-alone MS-DOS prompt window or if you launch the executable directly from Windows.
 
Mark D'soza
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Sameer,
Thank you very much for the reply. But seems I was not clear about the question. I asked thay why I am getting two diffrent results executing the same exe. one I was executing from Visual studio VC++ enviornment and one directly clicking the generated exe in the debug folder.
Today I got the answer. While execute a program from VC++, it uses files in the project directory whereas if double clicked on exe file in any directory, it searches for necessary files in the current directory, which in my case was Debug. I was missing one system file, so it was showing me diff results. Today I copied that file and wholla the result was same in both cases.
Anyways I again thank you for your help.
 
Why should I lose weight? They make bigger overalls. And they sure don't make overalls for tiny ads:
Free, earth friendly heat - from the CodeRanch trailboss
https://www.kickstarter.com/projects/paulwheaton/free-heat
reply
    Bookmark Topic Watch Topic
  • New Topic