Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

ÓÃvs2008½«c´úÂëÉú³ÉdllÎļþ - C/C++ / CÓïÑÔ

ÎÒÏÖÔÚÓÃvs2008Éú³ÉÁËdllÎļþ£¬ µ«ÊÇÔÚµ÷ÓÃʱ£¬Èç¹û´«ÈëbyteÀàÐ͵Äֵʱ£¬ÈôÕâ¸öÖµ´óÓÚ0x80£¬ÔÚdll½ÓÊÕµ½µÄȷʵÕâ¸öÖµµÄ²¹Âë¡£ÎÒºÜÓôÃÆ£¬ÔÚÍøÉÏ¿´·¢ÏÖʱ˵±àÂëÎÊÌ⣬vs±àÒëÆ÷ÎÒ²»ÊìϤ£¬ÎÒÓõÄÊÇgcc±àÒëÆ÷£¬ÏÖÔÚÐèÒªÒ»¸ödll¶¯Ì¬¿â¡£Ö®Ç°Éú³É¹ý£¬Ò²Äܹ»Ó㬺ÃÏñÊÇÔÚvsÀïÐÞ¸ÄÒ»¸öºêÖµ£¡ÄÄλ´ó¸çÓùý£¬ÅθæÖª£¡Ð»Ð»£¡
ÄãµÄ½è¿ÚÊDz»ÊǶ¨Òå³ÉcharÁË

Ó¦¸ÃÊÇÓзûºÅºÍÎÞ·ûºÅµÄÎÊÌâ¡£
0x80 = 128

Èç¹ûÄãÔÚ³ÌÐòÖе¥´¿µÄÓà char È¥¶¨ÒåÄãµÄ²ÎÊý£¬Õâ¸ö²ÎÊýÊÇÓзûºÅ»òÊÇÎÞ·ûºÅµÄÊÇÒª¿´±àÒëÆ÷ÁË¡£
signed char: -128 ~ 127
unsigned char :0 ~ 128
Èç¹ûÄãÒªÏëÄãµÄ²ÎÊýÄܹ»±íʾ´óÓÚ0x80µÄÊýÖµ£¬Äã¾ÍÒª¶¨Òå³ÉÎÞ·ûºÅµÄchar¼´£ºunsigned char.
ÕâÑù²ÎÊýÄܱíʾµÄ·¶Î§¾ÍÊÇ0~255ÁË¡£

ÉÏÃæ±ÊÎó£º

unsigned char : 0 ~ 255

LS ˵µÄû´í£¬ÀàÐÍÒªÍêÈ«Ò»Ö±£¬±ÜÃâ³öÏÖÊýÖµÒç³öÇé¿ö

en£¬ÓÃUCHAR

ÇëÎÊÉÏÃæµÄ¸÷λ£ºÓÐË­ÓÃvs½²c´úÂëÉú³ÉdllÎļþÁËÂð£¿

ÒýÓÃ
ÇëÎÊÉÏÃæµÄ¸÷λ£ºÓÐË­ÓÃvs½²c´úÂëÉú³ÉdllÎļþÁËÂð£¿

ÎÒ×ö¹ýC++µÄ
ÓõÄ2005
¸øDephiÓõÄ
µ±È»×Ô¼ºÒ²Óùý

ÒýÓÃ

ÇëÎÊÉÏÃæµÄ¸÷λ£ºÓÐË­ÓÃvs½²c´úÂëÉú³ÉdllÎļþÁËÂð£¿

Æäʵ£¬Äã¿ÉÒÔ½«ÄãµÄ´úÂëµÄ¹¦Äܲ¿·Ö¿½±´µ½Ò»¸öDLLµÄ¹¤³ÌÀïÃ棬DLL¹¤³ÌÄã¿ÉÒÔÔÚVSϽ¨Á¢£¬¿ÉÒÔÑ¡ÔñMFCÀàÐ͵ģ¬Õâ¸ö±È½Ï·½±ã£¬µ«ÊÇҪעÒâµÄÊÇ£¬ÄãҪѡÔñ¾²Ì¬Á´½Ó£¬ÒÔÃâµ½Óû§´¦Ã»ÓÐMFCµÄÀà¿â»á³öÏÖÎÊÌâ¡£
ÔÚ×öºÃDLLÖ®ºó£¬Äã¿ÉÒÔÔÚ¹¤³ÌÀïÃæÌí¼ÓÒ»¸ö.defΪºó׺µÄÎļþ£¬½«ÄãÒª¸øÓû§µÄ½Ó¿Ú¸øµ¼³ö£¬Ö»ÒªÐ´º¯ÊýÃû¾ÍºÃÁË£¬Õâ¸ö.defµÄ¸ñʽÎҾͲ»ËµÁË£¬Äã¿ÉÒÔ°Ù¶Èһϣ¬DLL


Ïà¹ØÎÊ´ð£º

linux»·¾³ÏÂgethostbynameº¯ÊýÎÊÌâ - C/C++ / CÓïÑÔ

дÁ˸ö²âÊÔ³ÌÐòÈçÏÂ
   
  struct hostent *hp; 
char AlarmDevIP[20];  
  int x2;

hp = gethostbyname("www.google.com");
if (hp)
{ ......

execlÔõôµ÷ÓÃjava³ÌÐò - C/C++ / CÓïÑÔ

ÈçÌ⣬C/C++ÖеÄexeclÔõôµ÷ÓÃдºÃµÄjava³ÌÐò£¬
execl("/opt/java1.5/bin/java","MyClass",NULL);
ÕâÑùµÄ²»ÐÐŶ¡£

²»»á.

ÔËÐÐjava³ÌÐò
ÕÒ¹¤¾ß²é¿´Ò»ÏÂÄǸö³ÌÐòµÄÃüÁîÐÐ

ËÑË÷Ï£ºjni ......

c¾²Ì¬±àÒëÁíÒ»¸öÎļþ¼ÐµÄ¿âº¯Êý - C/C++ / CÓïÑÔ

ÔÚ¸ùĿ¼/libÖдæ·ÅÒ»¸ölog.c£¬log.h£¬²¢ÓÃÏÂÃæµÄÓï¾ä£º
gcc -c log.c
ar crv liblog.a log.o
±àÒë³öÒ»¸öliblog.a¾²Ì¬¿â£¬È»ºóÔÚÎļþ¼Ð£º/testfileÖд´½¨Ò»¸ötest.cºÍtestc.c£¬test.cÖÐÒýÓÃÁËtestc.cÖж¨ÒåµÄ·½·¨ ......

visual c++2008²»ÄܱàÒëC³ÌÐòÂð - C/C++ / CÓïÑÔ

visual c++2008Ëٳɰ棬²»ÄܱàÒëC³ÌÐòÂð£¿Èç¹ûÄÜÊÇÔõô¿ªÊ¼µÄ°¡£¿ÓÃËü´øµÄÃüÁîÌáʾµ¥Ôª³ýÍâ ¡£
н¨¹¤³Ì£¨¿Õ¹¤³Ì»òwin32¿ØÖÆ̨£©

¾ø¶Ô¿ÉÒÔ¡£½¨Á¢win32¿ØÖÆ̨³ÌÐò¾Í¿ÉÒÔ

ÒýÓÃ
н¨¹¤³Ì£¨¿Õ¹¤³Ì»òwin32¿ØÖÆ̨£ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ