MFC中CString类型到char[]类型的转换

上传者: u013035197 | 上传时间: 2021-09-07 19:50:16 | 文件大小: 32.69MB | 文件类型: ZIP
用于WIN32开发时的编码转换函数 原型: void CString2Char CString str char ch[] ; 将str的字符串转换成char[]并放到ch里 解决了用memcpy 函数转换时字母后面多一个0的问题

文件下载

资源详情

[{"title":"( 51 个子文件 32.69MB ) MFC中CString类型到char[]类型的转换","children":[{"title":"CString2Char[]","children":[{"title":"CString2Char[].sln <span style='color:#111;'> 909B </span>","children":null,"spread":false},{"title":"CString2Char[]","children":[{"title":"stdafx.cpp <span style='color:#111;'> 147B </span>","children":null,"spread":false},{"title":"CString2Char[].h <span style='color:#111;'> 482B </span>","children":null,"spread":false},{"title":"res","children":[{"title":"CString2Char.rc2 <span style='color:#111;'> 680B </span>","children":null,"spread":false},{"title":"CString2Char[].ico <span style='color:#111;'> 66.19KB </span>","children":null,"spread":false}],"spread":true},{"title":"stdafx.h <span style='color:#111;'> 1.59KB </span>","children":null,"spread":false},{"title":"CString2Char[]Dlg.h <span style='color:#111;'> 704B </span>","children":null,"spread":false},{"title":"CString2Char[].rc <span style='color:#111;'> 10.00KB </span>","children":null,"spread":false},{"title":"targetver.h <span style='color:#111;'> 234B </span>","children":null,"spread":false},{"title":"CString2Char[].cpp <span style='color:#111;'> 2.03KB </span>","children":null,"spread":false},{"title":"CString2Char[].vcxproj.user <span style='color:#111;'> 143B </span>","children":null,"spread":false},{"title":"CString2Char[]Dlg.cpp <span style='color:#111;'> 4.03KB </span>","children":null,"spread":false},{"title":"resource.h <span style='color:#111;'> 1.52KB </span>","children":null,"spread":false},{"title":"CString2Char[].aps <span style='color:#111;'> 103.40KB </span>","children":null,"spread":false},{"title":"CString2Char[].vcxproj.filters <span style='color:#111;'> 1.99KB </span>","children":null,"spread":false},{"title":"Debug","children":[{"title":"vc100.idb <span style='color:#111;'> 1.91MB </span>","children":null,"spread":false},{"title":"CString2Char[]Dlg.obj <span style='color:#111;'> 46.13KB </span>","children":null,"spread":false},{"title":"CString2Char[].res <span style='color:#111;'> 68.02KB </span>","children":null,"spread":false},{"title":"CString2Char[].lastbuildstate <span style='color:#111;'> 66B </span>","children":null,"spread":false},{"title":"CString2Char[].vcxprojResolveAssemblyReference.cache <span style='color:#111;'> 713B </span>","children":null,"spread":false},{"title":"CL.write.1.tlog <span style='color:#111;'> 1.82KB </span>","children":null,"spread":false},{"title":"CL.read.1.tlog <span style='color:#111;'> 69.46KB </span>","children":null,"spread":false},{"title":"CString2Char[].log <span style='color:#111;'> 2.50KB </span>","children":null,"spread":false},{"title":"mt.read.1.tlog <span style='color:#111;'> 744B </span>","children":null,"spread":false},{"title":"rc.write.1.tlog <span style='color:#111;'> 654B </span>","children":null,"spread":false},{"title":"stdafx.obj <span style='color:#111;'> 627.91KB </span>","children":null,"spread":false},{"title":"rc.read.1.tlog <span style='color:#111;'> 3.62KB </span>","children":null,"spread":false},{"title":"CString2Char[].obj <span style='color:#111;'> 29.13KB </span>","children":null,"spread":false},{"title":"CString2Char[].exe.embed.manifest <span style='color:#111;'> 915B </span>","children":null,"spread":false},{"title":"mt.command.1.tlog <span style='color:#111;'> 812B </span>","children":null,"spread":false},{"title":"cl.command.1.tlog <span style='color:#111;'> 2.43KB </span>","children":null,"spread":false},{"title":"link-cvtres.read.1.tlog <span style='color:#111;'> 2B </span>","children":null,"spread":false},{"title":"CString2Char[].exe.intermediate.manifest <span style='color:#111;'> 640B </span>","children":null,"spread":false},{"title":"CString2Char[].exe.embed.manifest.res <span style='color:#111;'> 980B </span>","children":null,"spread":false},{"title":"link.write.1.tlog <span style='color:#111;'> 1.31KB </span>","children":null,"spread":false},{"title":"link-cvtres.write.1.tlog <span style='color:#111;'> 2B </span>","children":null,"spread":false},{"title":"link.command.1.tlog <span style='color:#111;'> 1.97KB </span>","children":null,"spread":false},{"title":"rc.command.1.tlog <span style='color:#111;'> 1.33KB </span>","children":null,"spread":false},{"title":"link.read.1.tlog <span style='color:#111;'> 5.49KB </span>","children":null,"spread":false},{"title":"CString2Char[].write.1.tlog <span style='color:#111;'> 0B </span>","children":null,"spread":false},{"title":"mt.write.1.tlog <span style='color:#111;'> 562B </span>","children":null,"spread":false},{"title":"CString2Char[]_manifest.rc <span style='color:#111;'> 218B </span>","children":null,"spread":false},{"title":"CString2Char[].pch <span style='color:#111;'> 32.19MB </span>","children":null,"spread":false},{"title":"vc100.pdb <span style='color:#111;'> 3.29MB </span>","children":null,"spread":false}],"spread":false},{"title":"CString2Char[].vcxproj <span style='color:#111;'> 5.84KB </span>","children":null,"spread":false},{"title":"ReadMe.txt <span style='color:#111;'> 3.06KB </span>","children":null,"spread":false}],"spread":false},{"title":"ipch","children":[{"title":"cstring2char[]-59edc0e6","children":null,"spread":false}],"spread":true},{"title":"CString2Char[].suo <span style='color:#111;'> 18.50KB </span>","children":null,"spread":false},{"title":"Debug","children":[{"title":"CString2Char[].pdb <span style='color:#111;'> 4.80MB </span>","children":null,"spread":false},{"title":"CString2Char[].ilk <span style='color:#111;'> 1.04MB </span>","children":null,"spread":false},{"title":"CString2Char[].exe <span style='color:#111;'> 150.00KB </span>","children":null,"spread":false}],"spread":true},{"title":"CString2Char[].sdf <span style='color:#111;'> 59.96MB </span>","children":null,"spread":false}],"spread":true}],"spread":true}]

评论信息

  • qq_32716885 :
    不错,虽然char ch[100]这个数组定义长了,除了显示想要显示的内容后还显示乱码,但是能出来。稍微修改下就没问题了。对我很有用
    2016-10-26

免责申明

【只为小站】的资源来自网友分享,仅供学习研究,请务必在下载后24小时内给予删除,不得用于其他任何用途,否则后果自负。基于互联网的特殊性,【只为小站】 无法对用户传输的作品、信息、内容的权属或合法性、合规性、真实性、科学性、完整权、有效性等进行实质审查;无论 【只为小站】 经营者是否已进行审查,用户均应自行承担因其传输的作品、信息、内容而可能或已经产生的侵权或权属纠纷等法律责任。
本站所有资源不代表本站的观点或立场,基于网友分享,根据中国法律《信息网络传播权保护条例》第二十二条之规定,若资源存在侵权或相关问题请联系本站客服人员,zhiweidada#qq.com,请把#换成@,本站将给予最大的支持与配合,做到及时反馈和处理。关于更多版权及免责申明参见 版权及免责申明