Re: Appending a long integer value to a CString variable
You could do something like:
CString csTime;
// Get time...
CTime cTime(time_stamp);
CString csTime = csTime.Format(_T("timestamp = %A, %B %d, %Y));
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vclib/html/_mfc_ctime.3a3a.ctime.asp
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vclib/html/_mfc_CTime.3a3a.Format.asp
Tom
"Prasad" <prasadk14@gmail.com> wrote in message
news:1158221771.116131.183740@d34g2000cwd.googlegroups.com...
HI all,
I have a long integer " time_stamp" which contains unix
timestamp value .
char *t=readLine(client);
char *pEnd;
unsigned long time_stamp=strtoul(t,&pEnd,0);
CString time="timestamp =";
When i try to append this time_stamp to a CString varable using
+ operator (like time+time_stamp), i am getting an error that "cannot
add two pointers"..
How could i do this ?
Or I need atleast some function to convert unix timestamp to a valid
date-string format ..
Thanx in advance,
Prasad