Shows how to use xtd::process class with standard output redirection.
#include <xtd/diagnostics/process>
#include <xtd/block_scope>
#include <xtd/console>
auto main() -> int {
try {
my_process.start_info().use_shell_execute(false);
my_process.start_info().file_name("guidgen");
my_process.start_info().create_no_window(true);
my_process.start();
}
}
catch (
const std::exception&
e) {
}
}
static void write_line()
Writes the current line terminator to the standard output stream using the specified format informati...
#define block_scope_(...)
The specified expression is cleared automatically when the scope is ended.
Definition block_scope.hpp:25
@ process
The IME PROCESS key.
Definition console_key.hpp:290
@ e
The E key.
Definition console_key.hpp:96
The xtd::diagnostics namespace provides classes that allow you to interact with system processes,...
Definition assert_dialog_result.hpp:10
The xtd namespace contains all fundamental classes to access Hardware, Os, System,...
Definition abstract_object.hpp:8