Ok, so you computed the value of Month. But you don't do anything with it. Remember, this is a variable that is local to the function only. Did you intend to return the value to the caller, perhaps?void GetMonth(string &date)
{
string Month;
Month = date.substr(0,2);
}
↧
Date manipulation question
↧