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

running a compiled program with parameters?

(1/1)

ixfd64:
This is probably a silly question, but:

Suppose that I want to run a program (let's call it "foo") that I just compiled, and that it takes in a parameter ("-bar"). Normally, I would run it by entering "foo -bar" in the command prompt.

However, can someone please tell me how to do the same in Code::Blocks? Obviously, clicking the "run" button only executes the program as "foo" (without the parameters).

Thanks.

ollydbg:
Hi, You should search the forum firstly. or you need to read or search on the C::B manual pdf. http://www.codeblocks.org/user-manual
I just search the forum by the key word:

--- Quote ---  command line argument
--- End quote ---
and there are many many answers of your question.

such as:
http://forums.codeblocks.org/index.php/topic,13711.0.html

xunxun:
Project -- Set program's argument -- Select your target -- Program arguments

ixfd64:
Thanks!

Navigation

[0] Message Index

Go to full version