VBcoders Browse New Submit Contact Sign In

No account? Register free

Forgot password?

Associate a file extension with your icon and your program.

Franco Breciano  (1 Submission)   Registry   Visual Basic 5.0   Unknown Difficulty   Mon 12th November 2001   Mon 8th February 2021

Associate a file extension with your icon and your program.

API Declarations


Alias "RegCreateKeyA" (ByVal hKey As Long, _
ByVal lpSubKey As String, _
phkResult As Long) As Long

Private Declare Function RegSetValue Lib "advapi32.dll" _
Alias "RegSetValueA" (ByVal hKey As Long, _
ByVal lpSubKey As String, _
ByVal dwType As Long, _
ByVal lpData As String, _
ByVal cbData As Long) As Long

' Return codes from Registration functions.
Const ERROR_SUCCESS = 0&
Const ERROR_BADDB = 1&
Const ERROR_BADKEY = 2&
Const ERROR_CANTOPEN = 3&
Const ERROR_CANTREAD = 4&
Const ERROR_CANTWRITE = 5&
Const ERROR_OUTOFMEMORY = 6&
Const ERROR_INVALID_PARAMETER = 7&
Const ERROR_ACCESS_DENIED = 8&

Private Const HKEY_CLASSES_ROOT = &H80000000
Private Const MAX_PATH = 260&
Private Const REG_SZ = 1

Private Declare Sub SHChangeNotify Lib "shell32.dll" _
(ByVal wEventId As Long, _
ByVal uFlags As Long, _
dwItem1 As Any, _
dwItem2 As Any)

Const SHCNE_ASSOCCHANGED = &H8000000
Const SHCNF_IDLIST = &H0&


Rate Associate a file extension with your icon and your program. (2(2 Vote))
Associate a file extension with your icon and your program..bas

Associate a file extension with your icon and your program. Comments

No comments yet — be the first to post one!

Post a Comment

0/1000 characters