CString str;
str.Format("%f", 1.2345);
AfxMessageBox(str);

 

 

float f= 123.4121;
char szBufffer[10];
sprintf(szBuffer, "%f", f);

posted on 2013-08-14 16:53  Yogurshine  阅读(160)  评论(0)    收藏  举报