sun_boy
驱动牛犊
驱动牛犊
  • 注册日期2005-06-29
  • 最后登录2014-12-25
  • 粉丝0
  • 关注0
  • 积分223分
  • 威望128点
  • 贡献值0点
  • 好评度19点
  • 原创分0分
  • 专家分0分
阅读:1120回复:0

请教字符格式转换问题。谢谢

楼主#
更多 发布于:2005-07-12 09:55
  m_strSectorContents是保存我从文件中读出的字符串,
char hexcode[10];
sprintf (hexcode, "%02X ", m_strSectorContents & 0xff); //转换成十六进制表示
我把hexcode处理后怎样再把它(保存到或)转换成m_strSectorContents的格式?
这样对吗?

  sprintf(retCode,"%u",(hexcode<<4)|hexcode[i+1]); 怎么得不到结果?请详细讲解一下,多谢你的帮助。
游客

返回顶部