VBcoders Browse New Submit Contact Sign In

No account? Register free

Forgot password?

AssociateFileType

Found on the World Wide Web  (15 Submissions)   Windows System Services   Visual Basic 3.0   Unknown Difficulty   Wed 3rd February 2021

Associate a file type with a program in windows95.

API Declarations
Declare Function RegCreateKey& Lib "advapi32.DLL" Alias "RegCreateKeyA" (ByVal hKey&, ByVal lpszSubKey$, lphKey&)
Declare Function RegSetValue& Lib "advapi32.DLL" Alias "RegSetValueA" (ByVal hKey&, ByVal lpszSubKey$, ByVal fdwType&, ByVal lpszValue$, ByVal dwLength&)
' Return codes from Registration functions.
Public Const ERROR_SUCCESS = 0&
Public Const ERROR_BADDB = 1&
Public Const ERROR_BADKEY = 2&
Public Const ERROR_CANTOPEN = 3&
Public Const ERROR_CANTREAD = 4&
Public Const ERROR_CANTWRITE = 5&
Public Const ERROR_OUTOFMEMORY = 6&
Public Const ERROR_INVALID_PARAMETER = 7&
Public Const ERROR_ACCESS_DENIED = 8&
Global Const HKEY_CLASSES_ROOT = &H80000000
Public Const MAX_PATH = 256&
Public Const REG_SZ = 1

Rate AssociateFileType (4(4 Vote))
AssociateFileType.bas

AssociateFileType Comments

No comments yet — be the first to post one!

Post a Comment

0/1000 characters