Text List size

Hi, what's the LotusScript syntax for getting the size of a TextList field?

> doc.TextListField

Who is Participating?
qwaleteeConnect With a Mentor Commented:
Dim doc as NotesDocument, item as NotesItem
Set doc = ..... 'whatever you want to set it to
Set item = doc.getFirstItem("nameOfTextListItem_orAnyItem_forThatMatter")
Print "Item occupied" item.valueLength "of storage"

This may not be the value you expect, as it includes overhead... Unicode characters can occupy two bytes... each element in the text list needs two bytes of storage to indicate element length... the text list itself needs two bytes to indicate the number of elements.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.