system( "ping www.google.com > pingresult.txt")
From this code can the string "ping www.google.com"
be taken from an std::string
variable? For example:
string ipAddress;
cout << "Enter the ip address: ";
cin >> ipAddress;
string ip = "ping" + ipAddress;
**system ("ip > pingresult.txt");** //error here
sytem("exit");