Hi Caixeta,
Depending on how you have stood up your program, there are a few ways to interact with it. If it exists as a standalone service, I would recommend setting up RESTful APIs that Mendix can call and your C++ program exposes. This would involve standing up the C++ program on a server somewhere, so that might not be ideal.
An alternative is to create a custom Java action that calls your C++ program directly. Mendix does not natively support extensions in C++, so you will need to find some mechanism to interface between Java and C++.
Here is more information on writing a Java action: https://docs.mendix.com/howto/logic-business-rules/extending-your-application-with-custom-java