Is this C or C++? How is the date originally stored? I assume it's a string, but you need to be more specific about what you need or we'll be of no help to you.
Narue
Bad Cop
15,460 posts since Sep 2004
Reputation Points: 6,483
Solved Threads: 1,407
Skill Endorsements: 54
if you know the format, then its pretty easy
string date = "01/02/2005"; // 1 Feb 2005
int month = atoi(date.substr(3,2).c_str());
// do day and year similar to above
Ancient Dragon
Achieved Level 70
32,122 posts since Aug 2005
Reputation Points: 5,836
Solved Threads: 2,575
Skill Endorsements: 69