Read with Formatting | Join TechSpot! (it's free) | Bookmark / Share this



launching .exe in visual c++

jlem
07-12-2004, 06:20 PM
newbie programming question. I am trying to launch an exe in a program, anyone tell me what to use for that?

MrGaribaldi
07-12-2004, 06:34 PM
Is it a complete program that you have compiled to a .exe?
If so, just navigate to where the program is located with the command prompt and type in the name of the .exe and hit enter.

you could also do it with the run prompt or explorer, but if you haven't created a GUI (or don't use any input or wait) it might close so fast you don't get to see anything.

If you haven't got a complete program but still want to test it, I have no idea. Could be a button, or in a menu, but might also not be.

What is the program you are trying to run?
(Use [ code ] [ /code ] without the spaces if you're posting the source code, as it makes it much easier to read)

Ad
07-12-2004, 06:34 PM

jlem
07-12-2004, 06:42 PM
I am just trying to make a program in c++ that has buttons for other programs that I need to launch. Kind like a menu program. In Visual C++ 2005 I creat the buttons but I need to tell it what to do, in this case open a program located in a dirctory like c:\alis\synchd.exe.


Make sense?

STK
07-12-2004, 09:41 PM
If I am not mistaken, I think it is: WinExec(program here) or ShellExecute(program here).

Good Luck, hope it works.

 Top Technology News

 Software Downloads

Copyright © 1998-2008 TechSpot.com. TechSpot is a registered trademark. All Rights Reserved.