主页C++ Builder 资料C++ Builder 参考手册System 字符串IntToStr
C++ Builder 串口控件
C++ Builder 编程技巧
C++ Builder 操作指南
C++ Builder 参考手册
基础知识
cfloat 浮点数
cmath 数学函数
cstdlib 标准库函数
System 字符串
 • UnicodeString
 • UTF8String
 • TStringList
 • TStrings
 • String
 • AnsiString
 • AnsiStringBase
 • AnsiStringT
 • RawByteString
 • UCS4String
 • WideString
 • EnumToStr
 • FloatToStr
 • FloatToStrF
 • FormatFloat
 • IntToStr
 • UIntToStr
 • IntToHex
 • StrToEnum
 • StrToFloat
 • StrToFloatDef
 • StrToInt
 • StrToIntDef
 • StrToInt64
 • StrToInt64Def
 • StrToUInt64
 • StrToUInt64Def
 • TFloatFormat
 • GetUnicodeCategory
 • IMLangCodePages
 • StringReplace
System 日期和时间
System.Math.hpp 数学函数
其他数据类型
VCL 基础类
VCL 应用程序
Pictures 图片
Graphics 绘图
Additional 控件
System 控件
A ~ Z 字母顺序排列的目录
网友留言/技术支持
IntToStr - 整数转字符串

函数原型:

UnicodeString __fastcall IntToStr(int Value);
UnicodeString __fastcall IntToStr(__int64 Value);

 

头文件:

#include <System.SysUtils.hpp> (XE2 之后),#include <SysUtils.hpp> (XE 之前)

 

参数:

Value: 为整数 int 或 __int64 类型。

 

返回值:

转换之后的字符串,以十进制转换。

 

例:

int i = 12345;
__int64 k = 9223372036854775807i64;
Edit1->Text = IntToStr(i);
Edit2->Text = IntToStr(k);

 

相关链接:

atoiatol_atoi64strtolstrtollstrtoulstrtoull
itoaltoaultoa_i64toa_ui64toa
IntToStrUIntToStrIntToHex
StrToIntStrToIntDefStrToInt64StrToInt64DefStrToUInt64StrToUInt64Def
EnumToStrStrToEnum

◤上一页:FormatFloat下一页:UIntToStr

C++ 爱好者 -- Victor Chen 的个人网站 www.cppfans.com 辽ICP备11016859号