 delphiתļ

ת:

    DateTimeToFileDate  DELPHIڸʽתΪDOSڸʽ 
    
    DateTimeToStr  ʱʽתΪַ 
    
    DateTimeToString  ʱʽתΪַ 
    
    DateToStr   ڸʽתΪַ     

    FileDateToDateTime    DOSڸʽתΪDELPHIڸʽ 
    
    FloatToDecimal    תΪʮ     

    FloatToStr    תΪַ     

    FloatToStr    תΪַ     

    FloatToText     ĸתΪʮ  
   
    FloatToTextFmt     ĸתΪʮ 
    
    IntToHex   תΪʮ     

    IntToStr    תΪַ     

    StringToWideChar   ANSIַתΪUNICODEַ
     
    StrToDate     ַתΪڸʽ     

    StrToDateTime    ַתΪ/ʱʽ 
    
    StrToFloat    ַתΪ   
  
    StrToInt    ַתΪ     

    StrToIntDef    ַתΪͻĬֵ  
   
    StrToTime    ַתΪʱʽ     

    TextToFloat   ַ(NULLĸʽ)תΪ 
    
    TimeToStr       ʱʽתΪַ   

    VarToDateTime         ıתΪʱ  
   
    WideCharLenToString    ANSIַתΪUNICODEַ 
    
    WideCharToString     UNICODEַתΪANSIַ   
  
    WideCharToStrVar    UNICODEַתΪANSIַ
 



һ:

õ:Integer(з),DWORD(32λ޷,Cardinalͬ),BOOL(FALSE..TRUEBooleanͬ)
BYTE(ֽ,PΪָ),Char(ַ,PΪָ),String(ַ),Single(ȸ,PΪָ)
Double(˫ȸ)

(1) :
    a :(ͨ<32λ>Integerз;Cardinal޷)
          :
         з:Shortint<8λ>Smallint<16λ>Longint<32λ >
         ޷:Byte<8λ>Word<16λ>LongiWord<32λ >
   
    bַ:(ͨ<8λ>Char AnsiCharͬ)
           壺
            AnsiChar<8λ> ҪAnsiַ
            WideChar<16λ>ҪUnicodeַ
    
    c:(ͨ<8λ>:BooleanByteBoolͬ)
           壺
            ByteBool<8λ>,WordBool<16λ>,LongBool<32λ>
           ͬĲҪԼͬwindowsϵͳݡ
   
     döͣ
           :type   öͱʶ(key1[=val1],....,keyn[=valn]) :n<=255
           ĳЩkeyֵָδֵָkeyǰһkeyֵ1
           ȫĬϲֵָkey1ֵΪ01

     eӽͣ
           :type ӽͱʶ½..½
           磺type SubInt1..30ʾ 130
                   type    SubChar'a'..'z'ʾַ

   ע1ͳΪͣһΪһⶼк

     ()޵ġ͵һţΪΪ䱾͵һ
	Ϊ0ε

         2ӽϡ½ͬһͣϽ½
      
    f:(ͨ<8ֽ>:RealDoubleͬ)
           :
           Double<8ֽ>,Real48<6ֽ>Single<4ֽ>,
           Extended<10ֽ>,Comp<8ֽ>,Currency<8ֽ>

     gַ:(ͨ:StringAnsiStringͬ)
           壺
           ShortString: 255ַ,һԼַ,NULLβ
           AnsiString: Ansiַ,NULLβ
          WideString: Unicodeַ,NULLβ
    
     hʱ䡢ͣTDateTime ʵǸ͵ı

(2):
   
    aָ:
         :type ָͱʶ^ͣ
         ڷ:New()         ڴͷ:Destroy()
         Pointer PChar   GetMem()AllocMem()ڴ棬FreeMem()ͷڴ

         ڴ,ͿԵɻһʹ:ָͱʶ^

         ʵϳָ:           
         var     ʶ:^ͣ
         ΪڴͿԽ(ʶ^)ͨʹá

   b¼:
         :type ¼ͱʶRecord
                      ֶ1:;
                      ...
                      ֶn:;
          end;

   c:
          :type ͱʶSet of   ͵Ӽӽ;(<=255Ԫ)

   d(ͨ):Variant;


(3):

     aһά:
           :type   ʶArray[±..±] of ;

     bλ:
           :type   ʶArray[1..1,...,n..n] of ;

    c̬():
          var   ʶ:array of ͣ
          SetLength(ʶ,),//ռ
          ʶ:=nil;//ͷ





   Ҫ˵һbegin  ...  end; ൱cc++е{...}.

   (1)
       const  ʶ[:]=ֵ;
       var  ʶ: ;

   (2)ʽ
       ɵĺϷ
       ȼ:     
       ȼ
       @ not 1                       ()
        *,/,div,mod,and,shl,shr,as,2
        +,-,or,xor ,3
        >,<,>=,<=,<>,=,in,is,4       ()

   (3) with   ...   do    ... end   
      Ҫڲ¼ͻʱʹá
      ʾtype people=Record                   //¼people
              name:string;
              addr:string;
              age:integer;
              sex:string;
            end;
       var Me:People;                 //people͵ı
           with Me do
           begin
                name:='Paul';
                addr:='Guangzhou';
                age:=23;
                sex:='male';
           end;

(4)goto 

     ˵ҪgotoʹãԾΪǡ
     ʾ:
          Label  MyLabel;  //LabelMyLabel

          MyLabel:  //
               ... //
          goto MyLabel;  //תMyLabel 



(5)


    aif ...   then ... 
         if    ʽ then   ..;
    if ʽ then 
      begin
       ...
      end;
        ʽ:
        if ...   then...  end  else begin...  end;

        if ..... then ....  else if ... then ...   else ...;

   bcase   ...   of  

         case ʽ of
                ֵ1:...
                ֵ2:...
                 ...
                ֵn:...
         end;




6)ѭ
   afor ...   to ... do 
      for ѭ:=ֵ to ֵ do   ...;
    for ѭ:=ֵ to ֵ do
       begin
          ...
       end;

   bwhile ... do 
      while ʽ do ...;
       while   ʽ   do
         begin
           ...
         end;

crepeat ... until   
       repeat    ...    until    ʽ

(7)ѭж
     break ѭ
     continueѭ
     goto()
     exit˳ǰ
     halt()ֹ򣬲Ϊ
     RunError()()


뺯

(1) (޷ֵ)
      :procedure <> (<б>);

(2)(зֵ)

     :function <> (<б>):ֵ;
     Result  <>غֵ
     ں Result:ֵ; <>:ֵ:;

ġ
	Try	...	except	...	end; If	...	else	...

ġDLLӿ

(1)̬

Function <DLL>(<1>:<1>; <2>:<2>):<ֵ>;
<Լ,StdcallCdecl>;external '<dllļ>' name '<DLL>';

(2)̬

type
<ָ>=function(<1>:<1>; <2>:<2>):<ֵ>;<Լ,StdcallCdecl>;
var
<DLL>:<>;
<>:<ָ>;
begin
<DLL>:=LoadLibrary('<dllļ>');
@<>:=GetProcAddress(<DLL>, '<DLL>');
<>(<;1>,<;2>);
