here the solution.
On VBA Code add PtrSafe after the Declare statements, *** TIP: Save file as .XLT
32Bit Config - VBA | 64Bit Config - VBA |
Private Declare Function SHBrowseForFolder _ Lib "shell32" _ ( _ lpbi As BrowseInfo _ ) _ As Long Private Declare Function SHGetPathFromIDList _ Lib "shell32" _ ( _ ByVal pidList As Long, _ ByVal lpBuffer As String _ ) _ As Long Private Declare Function lstrcat _ Lib "kernel32" _ Alias "lstrcatA" _ ( _ ByVal lpString1 As String, _ ByVal lpString2 As String _ ) _ As Long | Private Declare PtrSafe Function SHBrowseForFolder _ Lib "shell32" _ ( _ lpbi As BrowseInfo _ ) _ As Long Private Declare PtrSafe Function SHGetPathFromIDList _ Lib "shell32" _ ( _ ByVal pidList As Long, _ ByVal lpBuffer As String _ ) _ As Long Private Declare PtrSafe Function lstrcat _ Lib "kernel32" _ Alias "lstrcatA" _ ( _ ByVal lpString1 As String, _ ByVal lpString2 As String _ ) _ As Long |
Reference: http://www.integra4notes.com/faq/pages/0282