VB °æ (¾«»ªÇø)
·¢ÐÅÈË: bloom (©À©Á©Â©Ã©Ä©Æ©Ç¨), ÐÅÇø: VB
±ê Ìâ: RegCreateKeyEx(Îļþ´¦Àí)(תÔØ)
·¢ÐÅÕ¾: ¹þ¹¤´ó×϶¡Ïã (2000Äê09ÔÂ07ÈÕ18:40:34 ÐÇÆÚËÄ), תÐÅ
¡¾ ÒÔÏÂÎÄ×ÖתÔØ×Ô cnTemp ÌÖÂÛÇø ¡¿
¡¾ ÔÎÄÓÉ bloom Ëù·¢±í ¡¿
·¢ÐÅÈË: yucheng (ÎÞ»°¿É˵), ÐÅÇø: VisualBasic
·¢ÐÅÕ¾: BBS ˮľÇ廪վ (Sat Apr 8 02:04:16 2000) WWW-POST
RegCreateKeyEx
VBÉùÃ÷
Declare Function RegCreateKeyEx Lib "advapi32.dll" Alias "RegCreateKeyExA"
(ByVal hKey As Long, ByVal lpSubKey As String, ByVal Reserved As Long, ByVal
lpClass As String, ByVal dwOptions As Long, ByVal samDesired As Long,
lpSecurityAttributes As SECURITY_ATTRIBUTES, phkResult As Long,
lpdwDisposition As Long) As Long
˵Ã÷
ÔÚÖ¸¶¨ÏîÏ´´½¨ÐÂÏîµÄ¸ü¸´Ôӵķ½Ê½¡£ÔÚWin32»·¾³Öн¨ÒéʹÓÃÕâ¸öº¯Êý¡£ÈçÖ¸¶¨µÄÏîÒÑ
¾´æÔÚ£¬Ôòº¯Êý»á´ò¿ªÏÖÓеÄÏî
·µ»ØÖµ
Long£¬Á㣨ERROR_SUCCESS£©±íʾ³É¹¦¡£ÆäËûÈκÎÖµ¶¼´ú±íÒ»¸ö´íÎó´úÂë
²ÎÊý±í
²ÎÊý ÀàÐͼ°ËµÃ÷
hKey Long£¬Ò»¸ö´ò¿ªÏîµÄ¾ä±ú£¬»òÕßÒ»¸ö±ê×¼ÏîÃû
lpSubKey String£¬Óû´´½¨µÄÐÂ×ÓÏîµÄÃû×Ö
Reserved Long£¬ÉèΪÁã
lpClass String£¬ÏîµÄÀàÃû
dwOptions Long£¬ÏÂÊö³£ÊýΪÁ㣺REG_OPTION_VOLATILE¡ª¡ªÕâ¸öÏî²»Õýʽ±£´æÏÂÀ´£¬Ïµ
ͳÖØÐÂÆô¶¯ºó»áÏûʧ
samDesired Long£¬´øÓÐǰ׺KEY_??µÄÒ»¸ö»ò¶à¸ö³£Êý¡£ËüÃÇ×éºÏÆðÀ´ÃèÊöÁËÔÊÐí¶ÔÕâ¸ö
Ïî½øÐÐÄÄЩ²Ù×÷
lpSecurityAttributes SECURITY_ATTRIBUTES£¬¶ÔÕâ¸öÏîµÄ°²È«ÌØÐÔ½øÐÐÃèÊöµÄÒ»¸ö½á¹¹
£¨ÓÃByVal As Long´«µÝ¿ÕÖµ£©¡£²»ÊÊÓÃÓÚwindows 95
phkResult Long£¬Ö¸¶¨ÓÃÓÚ×°ÔØÐÂ×ÓÏî¾ä±úµÄÒ»¸ö±äÁ¿
lpdwDisposition Long£¬ÓÃÓÚ×°ÔØÏÂÁÐij¸ö³£ÊýµÄÒ»¸ö±äÁ¿£º
REG_CREATED_NEW_KEY¡ª¡ªÐ½¨µÄÒ»¸ö×ÓÏî
REG_OPENED_EXISTING_KEY¡ª¡ª´ò¿ªÒ»¸öÏÖÓеÄÏî
×¢½â
REG_OPTION_VOLATILE²»ÊÊÓÃÓÚwindows 95
Àý×Ó£º
1-49£¬
--
--
¡î À´Ô´:£®¹þ¹¤´ó×϶¡Ïã bbs.hit.edu.cn£®[FROM: blo0m.bbs@smth.org]
--
¡ù תÔØ:£®¹þ¹¤´ó×϶¡Ïã bbs.hit.edu.cn£®[FROM: 202.118.247.254]
Powered by KBS BBS 2.0 (http://dev.kcn.cn)
Ò³ÃæÖ´ÐÐʱ¼ä£º2.277ºÁÃë