在MFC应用程序的TextBox中显示二进制数据 [英] display binary data in TextBox in MFC application

查看:322
本文介绍了在MFC应用程序的TextBox中显示二进制数据的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好,
我想在MFC应用程序的文本框中显示二进制数据.我不知道该怎么做.

感谢

Hello,
I want to display binary data in text box in MFC application. I do not know how to do this.

Thanks

推荐答案

二进制数据的常规" 表示形式是十六进制形式,例如:
The ''usual'' representation of binary data is the hexadecimal one, for instance:
BYTE b[]= {10, 23, 51};
CString s;
s.Format(_T("%02X %02X %02X"), b[0], b[1], b[2]);



产生字符串"0A 17 33",您可以将其用作TextBox文本.



produces the string "0A 17 33" that you may use as the TextBox text.


这篇关于在MFC应用程序的TextBox中显示二进制数据的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆