Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » Community » Newbie corner » External .exe
External .exe [message #43243] Sun, 15 June 2014 17:09 Go to next message
idkfa46 is currently offline  idkfa46
Messages: 155
Registered: December 2011
Experienced Member
hi guys,
can i execute and external .exe from my app? how?

Regards,
Matteo
Re: External .exe [message #43244 is a reply to message #43243] Sun, 15 June 2014 18:00 Go to previous messageGo to next message
Klugier is currently offline  Klugier
Messages: 1076
Registered: September 2012
Location: Poland, Kraków
Senior Contributor
Hello idkfa46,

You can always use "system" function from c standard library to call external application.

// Example for GNU/Linux
#include <cstdlib>

int main() {
    system("/home/user/a.out"); // <- This function doesn't return program standard output!
}


Sincerely,
Klugier


U++ - one framework to rule them all.
Re: External .exe [message #43245 is a reply to message #43243] Sun, 15 June 2014 18:29 Go to previous messageGo to next message
dolik.rce is currently offline  dolik.rce
Messages: 1789
Registered: August 2008
Location: Czech Republic
Ultimate Contributor

idkfa46 wrote on Sun, 15 June 2014 17:09
can i execute and external .exe from my app? how?

Hi Matteo,

Of course, everything is possible with U++ Wink There are actually two ways. If you simply need to launch another program and wait until it finishes, there are Sys() functions. If you need to interact with the program or run it in non-blocking way, the there is LocalProcess class. Both options are documented.

Best regards,
Honza
Re: External .exe [message #43246 is a reply to message #43243] Sun, 15 June 2014 19:33 Go to previous message
idkfa46 is currently offline  idkfa46
Messages: 155
Registered: December 2011
Experienced Member
Thank you guys,
Later I'll try both solutions...

Smile matteo
Previous Topic: Drawine with Antyalyiasing
Next Topic: INTEL compilers
Goto Forum:
  


Current Time: Thu Apr 18 08:07:24 CEST 2024

Total time taken to generate the page: 0.02006 seconds