怎么将u_int32类型转换为字符串的ip地址(如:192.165.5.50)

如何将u_int32类型转换为字符串的ip地址(如:192.165.5.50)?
如何将u_int32类型转换为字符串的ip地址(如:192.165.5.50)?

------解决方案--------------------
inet_ntoa

char FAR * inet_ntoa( struct in_addr in );
举例:char * ipaddr=NULL;
char addr[20];
in_addr inaddr;
inaddr. s_addr=16777343;
ipaddr= inet_ntoa(inaddr);
strcpy(addr,ipaddr);
------解决方案--------------------
IntIP = ... // int ip address

Byte A = Byte(this-> IntIP > > 24);
Byte B = Byte(this-> IntIP > > 16);
Byte C = Byte(this-> IntIP > > 8);
Byte D = Byte(this-> IntIP);

editIP1-> Text = IntToStr(A);
editIP2-> Text = IntToStr(B);
editIP3-> Text = IntToStr(C);
editIP4-> Text = IntToStr(D);