I am trying to create a very complex program that...

I am trying to create a program that takes control of he mouse opens my compiler changes the code and runs it before closing out of the command prompt. Any help would be appreciated.I am using windows so i am using windows.h and winuser.h in my headers. I am using Code::Blocks compiler.
What it is supposed to do:
Run
output a number
Move mouse to open the compiler
Open program running in compiler
change text output
move mouse to build and run button and click
end program and repeat with next one

Thanks in advance!
Edit: I am currently working on some code for this. I will post what I have so far soon.
Last edited on
Why are you trying to do this by moving the mouse and clicking? There are far easier ways to accomplish your goal that do not require the existence of a mouse cursor or windowed application.
Last edited on
I know, I just am looking for a challenge
It won't work, Code::Blocks doesn't allow to run program multiple times at once.
This isn't a challenge, it's a bad idea. There's a difference.
Last edited on
oh, well I could at least end the program with the mouse on the build and run button
how is it a bad idea?
You're complicating a simple problem, and the knowledge you gain from solving it this way is not useful for anything other than complicating more simple problems. It is a waste of your time and you will not learn anything valuable.

If you insist on moving the mouse and simulating clicks, at least use the right tool for the job. That tool is not C++, it is any number of various macro programs that will enable you to do the same thing with ease. C++ is not the correct tool for this job. Knowing how to pick the correct tool for the job is vital in programming.
Last edited on
Topic archived. No new replies allowed.