Delphi IntegerתΪbyte[]
ÔÚDelphiÖÐIntegerÕ¼ÓÃ4¸ö×Ö½Ú£¬ÏÖÔÚÔõô°ÑÒ»¸öIntegerת»»Îª³¤¶ÈΪ4µÄbyte[] ?
byte(x) x:integer;
1Â¥£ºÐ´µÄʲô¶«¶«¡£
2Â¥£ºÎÒÈ¥ÊÔÒ»ÊÔ¡£
2Â¥£ºÕâ¸öд·¨ÊÇ´ó¶Ë»¹ÊÇС¶ËÄØ£¿
var
i:integer;
buf:array[0..3] of byte;
begin
move(i,buf[0],4);
end;
Type
PbyteAry=^TbyteAry;
TbyteAry=Array[0..3] of byte;
var b:TbyteAry;
i:integer;
begin
i:=1000;
//·½·¨1
move(i,b,SizeOf(TbyteAry));
//·½·¨2
b:=PbyteAry(@i)^;
//showmessage(inttostr(Integer(b)));
end;
»¹¿ÉÒÔǰ³ÌRecordµÄÀ´ÊµÏÖ£º
Type
TRec=Record
case boolean of
True:(Int:Integer);
False:(ByteAry:Array[0..3] of byte);
end;
var r:TRec;
begin
r.Int:=1000;
showmessage(inttostr(Integer(r.ByteAry)));
end;
var
bb : array[0..3] of byte;
a :integer;
a := 5;
move(a,bb,4);
¶àл¸÷λ!!2¥ͦºÃ¶®!!
Ïà¹ØÎÊ´ð£º
ÒÑÖªPython ÖУº
s = unicode("²âÊÔ", "gb2312")
s = u'\u6d4b\u8bd5'
print s
²âÊÔ
ÔÚDelphiÀïÃæÈçºÎ½«\u6d4b\u8bd5ÕâÑùµÄ»¹Ô³ÉGb2312µÄºº×ÖÄØ£¿
ÕÒµ½¸ö·½·¨
......
Çë½Ì¸÷·¸ßÊÖ¡£ÎäÁÖǰ±²¡£ÎÒ½«B.EXE×ö³É×ÊÔ´Îļþ£¬È»ºó¼Óµ½123.dllÖС£ÓÃA.EXEÀ´µ÷ÓÃ123.dllÖеÄB.EXE
Çë¸÷λǰ±²°ïæָ½ÌÏ¡£A.exeÈçºÎÀ´µ÷ÓÃdllÖеÄexe£¿´úÂëÓÖ¸ÃÈçºÎд£¿
ÎÞÈ˻شð£¿
×ö³É×ÊÔ´Î ......
ÇëÎÊDelphiÓÐÊ÷ÐοؼþÂð£¿
ÔõÑùʹÓã¿
Ttreeview
treeview.items.addchild(nil(Éϼ¶½Úµã),'°¸·¢Ê±·¢'(text));
raize ¿Ø¼þ°üÀïÃæÓУ¬csdnÓÐÏÂÔØµÄ
²é°ïÖúTTreeViewºÍTNodeÁ½¸öÀà
TTreeView ......
ÈçÌ⣬ µã»÷DelphiµÄFile²Ëµ¥µÄExitÍ˳öDelphi£¬ Delphi²¿·Ö¹Ø±Õ--¼´²»ÄÜÔÙ²Ù×÷Delphi£¬µ«ÈÎÎñÀ¸ºÍ½ø³ÌÀDelphi»¹ÔÚÔËÐУ¬Ã»ÓÐÕæÕýµÄÍ˳ö¡£ÊDz»Êǰ²×°ÁËjre¸Ä±äÁËijЩ»·¾³±äÁ¿µ¼Ö£¬ÇëÎʸßÊÖÈçºÎ½â¾ö£¿ ×¢£ºÃ»°²×° ......
´íÎóÀàÐÍ£º³ö´íÎó³¢ÊÔ¶ÁÈ¡»òдÈëÊܱ£»¤µÄÄÚ´æ¡£Õâͨ³£Ö¸Ê¾ÆäËûÄÚ´æÒÑË𻵡£
C#Ô´Âë
[DllImport("Base64.dll")]
public static extern string Base64ToStr(string Base64);
protected void Page_Load(o ......