I stumbled over this every now and the, but still have no idea what this error means.
Would be very handy to automatically set the selection, e.g. to group records or script testing
The script throws the error on this line
set selectRecords to sel & thisRecord
property targetSelectionCount : 5
tell application id "DNtp"
set win to viewer window 1
set theGroup to root of win
set theRecords to children of theGroup
repeat with thisRecord in theRecords
set sel to selection of win
set selCount to count of sel
if selCount < targetSelectionCount then
set selectRecords to sel & thisRecord -- error "vector"
set selection of win to selectRecords
on error error_message number error_number
if the error_number is not -128 then display alert "DEVONthink" message error_message as warning