Hi,
Sorry for the problem with 64 bit. Try replacing the line in red above with the following which should work in both 32 bit and 64 bit Excel:
#If VBA7 And Win64 Then
' 64 bit Excel
'The following line is supposed to be RED in 32 bit Excel
Public Declare PtrSafe Sub Sleep Lib "kernel32" (ByVal dwMilliseconds As Long)
#Else
' 32 bit Excel
Public Declare Sub Sleep Lib "kernel32" (ByVal dwMilliseconds As Long)
#End If
I suggest you update your profile to change the office version from '2013' to '64 bit 2013'. This will help you get more accurate responses in the future.
Lewis
Bookmarks