User forums > General (but related to Code::Blocks)

Where is output file in codeblocks ?

(1/2) > >>

vikash:
I make this code

--- Code: ---#include <iostream>

using namespace std;

int main()
{
    cout << "Hello world!" << endl;
    int a(0);
    cin>>a;
    return 0;
}

--- End code ---
it runs when i press F9 but where is this final resultant file. I try at this location project_folder/bin/debug/ in this location their is only one file and it is not running. I have changed code retry but failed. Before today i code in windows 7 but today i code this in xubuntu 11.04.I find .exe file easily their(in windows). So finally tell me where is final resultant file(named as exe in windows).

vikash chandola

ouch:
it's wherever you put it... check your project settings.

if you didn't change it then look for a bin folder in your projects main directory, it's probably in there.

Jenna:
What exactly do you mean with "is not running".
You should know, that executables in linux have (in most cases) no file-endings.
If you double-click a console program it might open and close so fast, that you do not see it.

You should try it from a console:
cd to the folder, where it is located and start it with ./exename

vikash:

--- Quote from: ouch ---it's wherever you put it... check your project settings.

if you didn't change it then look for a bin folder in your projects main directory, it's probably in there.

--- End quote ---
Yes it is their but not running either in double click or single click(i have changed setting to single click).

--- Quote from: jens on July 12, 2011, 06:27:40 pm ---What exactly do you mean with "is not running".
You should know, that executables in linux have (in most cases) no file-endings.
If you double-click a console program it might open and close so fast, that you do not see it.

You should try it from a console:
cd to the folder, where it is located and start it with ./exename

--- End quote ---
their is a file name like project and have no extensions(in bin folder).
As you can see in code i provide it is required to input something to to end that so it should there for some seconds but it is not there for even a second.

Nothing happens when i double click or single click this file. At least it should appear for very small time but it doesn't appear even for fraction of second.

NOTE: when i debug it asks for input(a) and then close.

Jenna:
Normally linux does not automatically open a console, so:

--- Quote from: jens on July 12, 2011, 06:27:40 pm ---cd to the folder, where it is located and start it with ./exename

--- End quote ---

Navigation

[0] Message Index

[#] Next page

Go to full version