Delphi²Ù×÷×¢²á±íµÄÒ»°ã²½Öè
Delphi²Ù×÷×¢²á±í²½ÖèÈçÏ£º
-------------------------------------
1£©ÔÚUsesÖÐÌí¼ÓRegistryµ¥Ôª£»
2£©ÉùÃ÷TRegistry¶ÔÏó£»
3£©´´½¨TRegistry¶ÔÏó£»
4£©Ö¸¶¨¸ù¼ü£»
----------------try------------------
5£©´ò¿ªÐèÒª²Ù×÷µÄÖ÷¼ü£»
6£©¶Áд²Ù×÷£»
7£©±£´æ²¢¹Ø±ÕÖ÷¼ü£»
--------------finally----------------
8£©ÊÍ·ÅTRegistry¶ÔÏó£»
---------------end------------------
==========================================================
Uses Registry; //Ìí¼ÓRegistryµ¥Ôª£»
var
MyReg: TRegistry; //ÉùÃ÷TRegistry¶ÔÏó£»
begin
MyReg := TRegistry.Create; //´´½¨TRegistry¶ÔÏó£»
try
MyReg.RootKey := HKEY_LOCAL_MACHINE; //Ö¸¶¨¸ù¼ü£»
if MyReg.OpenKey('Ö÷¼üÃû', true) then //´ò¿ªÐèÒª²Ù×÷µÄÖ÷¼ü£»
begin
MyReg.ReadType(---); //¶Á×¢²á±íÎļþ
MyReg.WriteType(---); //дע²á±íÎļþ
end;
MyReg.CloseKey; //±£´æ²¢¹Ø±ÕÖ÷¼ü£»
finally
MyReg.Free; //ÊÍ·ÅTRegistry¶ÔÏó£»
end;
end;
==========================================================
function OpenKey(const Key:String; CanCreate:Boolean):Boolean;
//µÚ¶þ¸ö²ÎÊýÖ¸Ã÷£¬Èç¹ûÐèÒª´ò¿ªµÄÖ÷¼ü²»´æÔÚʱÊÇ·ñ´´½¨¸ÃÖ÷¼ü
function CreateKey(const Key:String):Boolean;
//´Ë·½·¨ÓÃÓÚ´´½¨Ö÷¼ü£¬Êµ¼ÊÉϲ¢²»³£ÓÃ
function KeyExists(const Key:String):Boolean;
//ÅжÏÖ÷¼üÊÇ·ñ´æÔÚ
(***¶ÔÓÚ×Ö·û´®ÀàÐ͵IJÙ×÷º¯Êý***)
function ReadString(const Name: String):String;
procedure WriteString(const Name, Value: String);
//¶ÔÓÚÆäËüÊý¾ÝÀàÐ͵Ä×¢²á±í¶Áд
Ïà¹ØÎĵµ£º
DelphiµÄ·½·¨ÀàÐÍÓУº
1.¾²Ì¬·½·¨ (Static) ĬÈÏÀàÐÍ£¬¿ÉÒÔÊ¡ÂԹؼü×Ö
2.ÐéÄâ·½·¨ (Virtual)
3.¶¯Ì¬·½·¨ (Dynamic)
4.ÏûÏ¢·½·¨ (Message)
5.³éÏó·¨·½ (Abstract)
=======================================================
1£©¾²Ì¬·½·¨[static]
¾²Ì¬·½·¨ÀàËÆÓÚͨ³£µÄ¹ý³ÌºÍº¯Êý£¬±àÒëÆ÷ÔÚ±àÒëʱ¾ÍÒÑÖ¸¶¨ÁËÊä³ö¸Ã·½· ......
Day ¿ªÍ·µÄº¯Êý
¡ñ
Unit
DateUtils
function DateOf(const Avalue: TDateTime): TDateTime;
ÃèÊö
ʹÓà DateOf º¯ÊýÓÃÀ´°ÑÒ»¸ö TDateTime ÀàÐ͵ıäÁ¿×ª±ä³ÉÒ»¸ö
Ö»´øÓÐÈÕÆÚµÄ TDateTime ÀàÐͱäÁ¿¡£
ÀýÈ磺
showmessage(DateTimetostr(dateof(now())));
ÄãµÃµ½µÄÊÇ 2003/03/19
¶ø showmessage(Dat ......
ÒÔÏÂÊÇtest.htmÒ³µÄÄÚÈÝ
Ê×Ïȶ¨ÒåÒ»¸ö²å¼þ¶ÔÏó
<object id="Mapupload" name="Mapupload" width="0" height="0" classid="clsid:045FA9B9-B373-4D4C-AE76-128A19A4B6AE">
</object>
<script type="text/javascript">
//´Ëº¯Êý´ò¿ªactivexform´°Ì岢Ϊactiv ......
3.2 Óû§µÇ¼·½°¸
ÔÚ½øÈëÒ»¸öϵͳʱ£¬±ØÐëÏÈÔڵǼ´°ÌåÖÐÊäÈëÕýÈ·µÄÓû§ÃûºÍÃÜÂë²ÅÄܽøÈë¡£ÕâÑù¿ÉÒÔÈ·±£ÏµÍ³µÄ°²È«ÐԺͱ£ÃÜÐÔ£¬µÇ¼´°ÌåµÄÖÆ×÷°´ÕÕϵͳµÄ´óС¼°Óô¦£¬¿ÉÒÔ·ÖΪ²»Í¬µÄµÇ¼´°ÌåÑùʽ£¬ÔÚϵͳµÚÒ»´ÎµÇ¼ǰ£¬Ê×ÏÈÒª¶Ô²Ù×÷Ô±ÐÅÏ¢½øÐÐÏàÓ¦µÄÉèÖᣱ¾½Ú½«¶ÔµÇ¼´°Ìå¼°²Ù×÷Ô±¹ÜÀí´°ÌåµÄÖÆ×÷¹ý³Ì½øÐÐÏêϸµÄ˵Ã÷ ......