I get an error 1004 "Application-defined or object-defined error". with the subroutine:
Sub test()
Dim I As Double
Dim Map As String
Dim ActualFileName As String
Dim MapAndFile As String
Dim Index As Integer
Dim WorksheetNaam As String
I = 67091
WorksheetNaam = "Dir"
Map = "D:\Foto's en video's\Fotos\Familie\FritsEnMo\2004\Mei\Wouter"
ActualFileName = "Frits240b24e3a6.jpg"
Cells(I, 4) = ActualFileName
MapAndFile = Map & "\" & ActualFileName
With Worksheets(WorksheetNaam)
.Hyperlinks.Add .Cells(I, 6), MapAndFile
End With
End Sub
With I up to 67090 there are no problems, but from I=67901 and higher I get the error 1004 message on '.Hyperlinks.Add .Cells(I, 6), MapAndFile'.
The http://msdn.microsoft.com/en-us/libr...ice.15%29.aspx gave me no solution.
Can anyone helps me?
With kind regards
Jan Lichtenbelt
Bookmarks