< Back

Document Subject: Adding entry will cause text list to exceed 64K. Entry not added.
Hint Short Cut: Add this to your code & documentation to help you find this page.
http://#64k or http://A555F9/nn.nsf/ByAlias/64k

Lotus Notes Error: Adding entry will cause text list to exceed 64K. Entry not added. occurs when creating an array that is too large for a document.




 

One way to avoid this is to keep track of the size of the array:

 

I assue an array is size of strings + (2 * number of elements)

64k being 65536 64 * 1024 bytes   i use 64000 instead as a safety marker.

 

 

redim people(0) as string

peepcount=0

n =  "name etc"
if peepsize+Len(n) +(peepcount*2)> 6400  then '65536

   'do something else like add to another array instead

else

  peepcount=peepcount+1
Redim Preserve people(peepcount)
 people(peepcount)=n
 
 peepsize=peepsize + Len(n)
end if
 
Dim ni As notesitem
Set ni = currdoc.replaceitemvalue("ListOfPeople", people)
ni.IsSummary=False