home *** CD-ROM | disk | FTP | other *** search
/ Programmer Plus 2007 / Programmer-Plus-2007.iso / Programming / Microsoft Plateform / Visual Basic 5.0 / Msvb50.ace / msvb50 / MSVB50 / VB / TEMPLATE / MODULES / ADDIN.BAS
Encoding:
BASIC Source File  |  1996-11-14  |  707 b   |  16 lines

  1. Attribute VB_Name = "AddIn"
  2. Option Explicit
  3. Declare Function WritePrivateProfileString& Lib "Kernel32" Alias "WritePrivateProfileStringA" (ByVal AppName$, ByVal KeyName$, ByVal keydefault$, ByVal FileName$)
  4.  
  5. '====================================================================
  6. 'this sub should be executed from the Immediate window
  7. 'in order to get this app added to the VBADDIN.INI file
  8. 'you must change the name in the 2nd argument to reflecty 
  9. 'the correct name of your project
  10. '====================================================================
  11. Sub AddToINI()
  12.     Dim ErrCode As Long
  13.     ErrCode = WritePrivateProfileString("Add-Ins32", "MyAddIn.Connect", "0", "vbaddin.ini")
  14. End Sub
  15.  
  16.