| | |
exe application
Please support our C++ advertiser: Intel Parallel Studio Home
![]() |
•
•
Join Date: Mar 2004
Posts: 12
Reputation:
Solved Threads: 0
how would you make a simple exe application for something like this in vis c++. so that you could send it self contained and a person double clicks it and it runs. please show the code and where you would enter it.
thanks
#include <iostream>
using std::cout;
using std::cin;
int main()
{
int a, b, sum;
cout << "enter first number\n";
cin >> a;
cout << "enter second number\n";
cin >> b;
sum = a + b;
cout << "sum is " << sum << std::endl;
return 0;
}
thanks
#include <iostream>
using std::cout;
using std::cin;
int main()
{
int a, b, sum;
cout << "enter first number\n";
cin >> a;
cout << "enter second number\n";
cin >> b;
sum = a + b;
cout << "sum is " << sum << std::endl;
return 0;
}
•
•
Join Date: Mar 2004
Posts: 11
Reputation:
Solved Threads: 1
To do this, create a new project (workspace if using vc++ 6) add a new code file, paste your code in there, compile (I believe F7 in vc++ 6, or ctrl-shift-B in vs.net), the exe will be in your project folder, send that to anyone with windows, and it will be able to run, you aren't using anything that needs to be installed.
•
•
Join Date: Mar 2004
Posts: 77
Reputation:
Solved Threads: 2
visual studio usually ships 'neutered', meaning you can't build standalone apps to distribute. depending on what version u have, this is may or may not be true. usually the expensive, ie. Professional Version, lets u build standalone apps. this is done by going to Build->Configurations and selecting Release mode instead of debug mode.
•
•
Join Date: Mar 2004
Posts: 11
Reputation:
Solved Threads: 1
Debug mode is standalone, the exe just contains debugging information, that allows you to step through the code when you set a breakpoint inside the IDE. Even Academic versions allow you to create standalone apps. The license agreement though says that you can't sell any app created by that version of the IDE (I know I got the academic version, and I can send you a C++ OpenGL program compiled in Debug mode that will run standalone)
•
•
Join Date: Mar 2004
Posts: 12
Reputation:
Solved Threads: 0
i thought i had the "neutered" version as well. i have enterprise edition and used to have pro i think and could do it easy enough in visual basicwhich has the option to make an exportable exe option. but here in vis c++ i can't seem to do it. file>new>win 32 con app>empty project and such with no luck in make that exe. i haave check the project files and only have .cpp dsp dsw opt and html doc. no exe...
•
•
Join Date: Mar 2004
Posts: 11
Reputation:
Solved Threads: 1
Yeah exactly what infamous said it will be in you Debug folder.
@infamous:It may have been that way in previous versions of visual studio, i'm not sure never had it before, and now I get vs.net free from school through the msdnaa. This is the clearest source i could find on the license restrictions http://www.ben.edu/programs/business/msdnaa/
Basically it says I can only use my copy of visual studio .net 2003 for instructional and non-commercial use. (i.e. can't use it to make stuff to sell, would have to buy at least the professional version for that.)
@infamous:It may have been that way in previous versions of visual studio, i'm not sure never had it before, and now I get vs.net free from school through the msdnaa. This is the clearest source i could find on the license restrictions http://www.ben.edu/programs/business/msdnaa/
Basically it says I can only use my copy of visual studio .net 2003 for instructional and non-commercial use. (i.e. can't use it to make stuff to sell, would have to buy at least the professional version for that.)
![]() |
Similar Threads
- Explorer.Exe - Application Error (Windows NT / 2000 / XP)
- Explorer.EXE-Application Error????? (Windows NT / 2000 / XP)
- ActiveMovie Window: explorer.exe - Application Error (Windows NT / 2000 / XP)
- Help in error:IEXPLORE.EXE - Application Error (Web Browsers)
- Iexplore.exe application failed?? (Web Browsers)
Other Threads in the C++ Forum
- Previous Thread: For the newbees (like myself)
- Next Thread: I need help on my 'address book' assignment!
| Thread Tools | Search this Thread |
api array arrays based beginner binary c++ c/c++ calculator char char* class classes code compile compiler console conversion count delete deploy desktop directshow dll download dynamic dynamiccharacterarray encryption error file forms fstream function functions game givemetehcodez google graph gui homeworkhelp homeworkhelper iamthwee ifstream input int integer java lib linkedlist linker linux list loop looping loops map math matrix memory news number numbertoword output parameter pointer problem program programming project python random read recursion recursive reference return rpg sorting string strings struct temperature template templates test text text-file tree unix url variable vector video visual visualstudio win32 windows winsock wordfrequency wxwidgets





