Hello all,

Iam trying to save the ping results obatined in a text file in c++.

Below is a copy of my code. Any advice will be greatly appreciated.

I keep getting this error:

c_str()) was unexpected at this time.
Code:
#include <iostream>
#include <string>
#include <windows.h>

using namespace std;

static string host;
static string
...