VC++ 基本类型转换与操作的知识积累

1、下面这样的写法是错的。最后strtmp的值会是"000000000000"

      CString strTmp = "111211";

      strTmp.Format("%012s",strTmp);

      下面的是正确的。strAmount最后的结果是"000000111211"

      CString strTmp = "111211";

      CString strAmount;

      strAmount.Format("%012s",strTmp);

猜你喜欢

转载自o396032767.iteye.com/blog/2408360