Delphi ÈÕÆÚº¯Êý
Day ¿ªÍ·µÄº¯Êý
¡ñ
Unit
DateUtils
function DateOf(const Avalue: TDateTime): TDateTime;
ÃèÊö
ʹÓà DateOf º¯ÊýÓÃÀ´°ÑÒ»¸ö TDateTime ÀàÐ͵ıäÁ¿×ª±ä³ÉÒ»¸ö
Ö»´øÓÐÈÕÆÚµÄ TDateTime ÀàÐͱäÁ¿¡£
ÀýÈ磺
showmessage(DateTimetostr(dateof(now())));
ÄãµÃµ½µÄÊÇ 2003/03/19
¶ø showmessage(DateTimetostr((now())));
µÃµ½µÄÊÇ 2003/03/19 10:50:49
¡ñfunction DateTimeToStr(DateTime: TDateTime): string;
ÃèÊö
DateTimeToString º¯Êý½« TDateTime ÀàÐ͵IJÎÊý DateTime ת»»³ÉÒ»¸ö
×Ö·û´®£¬Ê¹Óøø¶¨µÄÈ«¾Ö±äÁ¿ ShortDateFormat µÄ¸ñʽ£¬Ê±¼ä²¿·Ö°´ÕÕ
¸ø¶¨µÄÈ«¾Ö±äÁ¿ LongTimeFormat µÄ¸ñʽ¡£
ÆäÖÐ DateTime ΪÁãµÄ²¿·Ö½«²»»áÏÔʾ³öÀ´¡£
ÀýÈ磺
ShortDateFormat:=’yyyy mm dd’;
showmessage(DateTimetostr((now())));
Ä㽫µÃµ½£º2003 03 19 10:50:49
¡ñprocedure DateTimeToString(var Result: string; const Format: string; DateTime: TDateTime);
ÃèÊö£º
DateTimeToString ·½·¨½«TDateTimeÀàÐ͵IJÎÊýDateTime °´ÕÕÓɲÎÊýFormatÌṩµÄ¸ñʽ
ת»¯³É×Ö·û´®£¬²¢±£´æÔÚResultÖС£
¶ÔÓÚFormatµÄ¸ñʽÀàÐÍ£¬Çë¿´ Date-Time format strings µÄ°ïÖú¡£
ÀýÈ磺
DateTimeToString(result,’yyyy mm dd’,now());
ÄÇô resultµÄ½á¹ûΪ£º2003 03 19 10:50:49
¡ñprocedure DateTimeToSystemTime(DateTime: TDateTime; var SystemTime: TSystemTime);
ÃèÊö£º
ÓÐʱΪÁ˵÷ÓÃAPIº¯ÊýÀ´Ê¹ÓÃϵͳʱ¼ä£¬Äã¿ÉÒÔʹÓà DateTimeToSystemTime ·½·¨£¬À´½«Ò»¸ö
TDateTime ÀàÐ͵Äʱ¼ä±äÁ¿×ª»»³ÉÒ»¸ö TSystemTime ÀàÐÍµÄ ÏµÍ³Ê±¼ä¡£
¡ñfunction DateTimeToUnix(const Avalue: TDateTime ): Int64;
ÃèÊö£º
ʹÓà DateTimeToUnix º¯ÊýÀ´½«Ò»¸ö TDateTime ÐÍʱ¼ä±äÁ¿×ª»»³ÉÒ»¸öÏàÓ¦µÄ Unix ¸ñʽ
µÄÈÕÆÚºÍʱ¼ä¡£
Unix date-and-time values are encoded as the number of seconds that have elapsed
since midnight at the start of January 1, 1970.
¡ñfunction DateToStr(Date: TDateTime): string;
ÃèÊö£º
ʹÓà DateToStr º¯ÊýÄܵõ½ TDateTime ÈÕÆÚʱ¼äÀàÐ͵ÄÈÕÆÚ²¿·Ö¡£ÈÕÆÚµÄת»»¸ñʽÒÀÀµÓÚ
È«¾Ö±äÁ¿ ShortDateFormat¡£
¡ñfunction DayOf(const Avalue: TDateTime): Word;
ÃèÊö£º
¶ÔÓÚ¸ø¶¨µÄTDateTimeÀàÐ͵ÄÈÕÆÚʱ¼ä£¬Ê¹Óà DayOf º¯ÊýÄܵõ½¸ÃÈÕÆÚÊǸÃÔ·ݵÄ
Ïà¹ØÎĵµ£º
delphiÖÐapplication.processmessagesµÄ×÷ÓÃ
procedure TForm1.Button2Click(Sender: TObject);
var
I, J, X, Y: Word;
begin
I := 0;
J := 0;
while I < 64000 do
begin
Randomize;
& ......
±±¾©ÌÚ¶ÈÍøÂç¿Æ¼¼ÓÐÏÞ¹«Ë¾
µØÖ·:±±¾©º£µíÇøÑ§Çå·
µç»°:82755789
Òò¹¤×÷ÐèÒª,ÏÖÃæÏò±±¾©ÕÐÆ¸ÒÔÏÂְλ.
DelphiÈí¼þ¹¤³Ìʦ
1¡¢¾«Í¨Delphi¿ª·¢£¬ÊìϤVCL¼Ü¹¹£¬´úÂë·ç¸ñÁ¼ºÃ¡£
2¡¢ÓÐÁ¼ºÃµÄÍŶӺÏ×÷¾«Éñ£¬¸»Óд´Ð¾«Éñ;
3¡¢ÊìÏ¤ÍøÂç±à³Ì£¬¶ÔIndy×é¼þ£¬Socket¿ª·¢ÓÐÒ»¶¨µÄÁ˽â;
4¡¢ÊìÏ¤ÃæÏò¶ÔÏó±à³Ì˼Ïë,ÓÐ×é¼þ»ò¿Ø¼þ±à ......
//**************ÐèҪǿµ÷µÄÁ½¸ö¿ì½Ý¼ü**********************
51.CTRL+SHIFT+U ´úÂëÕû¿é×óÒÆ2¸ö¿Õ¸ñλÖÃ
52.CTRL+SHIFT+I ´úÂëÕû¿éÓÒÒÆ2¸ö¿Õ¸ñλÖÃ
60.Ctrl+Alt+c ×¢ÊÍ¿é
61.Ctrl+Alt+u & ......
±êÌâ
Delphi¶à²ã¿ª·¢·½°¸±È½Ï £¨×ªÔØ£©
¹Ø¼ü×Ö
Delphi¶à²ã¿ª·¢·½°¸±È½Ï
³ö´¦
·½°¸->
Midas
DCOM
COM+
ASTA
RemoteObject
.NET
ÌṩÕß
Borland
΢Èí
΢Èí
http://www.astatech.com
http://www.remobjects.com
΢Èí
ºËÐļ¼Êõ
COM
COM
COM
ASTA×Ô¼ ......
·½·¨Ò»£º
Ö±½Óµ¯³öUDL¶Ô»°¿ò:
use
ADOConed;
EditConnectionString(ADOQuery1);
·½·¨¶þ£º
¢Å¡¢ÓÒ¼ü---н¨---Îı¾Îĵµ£¬ÖØÃüÃûΪ connSet.udl ¡£
¢Æ¡¢Ë«»÷´ò¿ª connSet.udl °´Ìáʾ²Ù×÷ÅäÖÃÊý¾Ý¿â£¬Ñ¡Ôñ±¾µØ»òÔ¶³ÌÊý¾Ý¿â£¬ÅäÖúúóÍ˳ö¡£
¢Ç¡¢Ê¹ÓÃDelphi ¿Ø¼þTADOConnectionÁ¬½Ó´úÂ룺
ÔÚForm ......