MAJOR ISSUE: Note Item Not Found & Attachments at Bottom of Doc

Hello,

I have a db with some documents that have corrupt attachments. When users attach documents, we have this code that runs when the doc is saved that removes the attachment from the editable field and appends it to another computed field with pre-existing attachments that were already submitted.

Sometimes (and usually when there are just too many attachments in this computed RT field) corruption takes place when the user submits a new attachment. The attachments in the computed field will not open - you get Note Item Not Found. And the attachments show up at the bottom of the form. Keep in mind. the field still exists so not sure why they show up at the bottom of the form.

We are rewriting the way this is done, so I have a fix for the future, but I’m trying to determine which documents in my existing database have corrupted attachments at the bottom of the form. I try to run an agent on a specific document that I know has corrupted attachments to set a field if the $V2AttachmentOptions field exists. I can see that it exists in the doc properties, but my agent doesn’t seem to recognize this field.

Is there any other way I can determine which documents in my database have attachments at the bottom of the document?

Thanks in advance,

Laurie

Subject: MAJOR ISSUE: Note Item Not Found & Attachments at Bottom of Doc

V2-style attachments will appear in the document.EmbeddedObjects collection, while attachments linked from rich text fields will not. And computed rich text fields are the reason for your current problem – they are limited by the computation process in ways that editable rich text fields never will be. It would probably be better to remove edit permissions for the catchall document from the user and have them submit new attachments using a separate document.

Subject: RE: MAJOR ISSUE: Note Item Not Found & Attachments at Bottom of Doc

Hi. Thanks for your quick response.

I have a fix for my new design. At this point I am just trying to determine “which” existing documents have documents at the bottom of the form OR attachments that have the Item Not Found Error by flagging them with an agent.

Any thoughts on if that can be done?

Thanks,

Laurie

Subject: RE: MAJOR ISSUE: Note Item Not Found & Attachments at Bottom of Doc

Like I said, attachments that are not associated with a rich text field will be available through the EmbeddedObjects collection of the document itself (attachments with an associated rich text link are not).

Subject: Note Item Not Found & Attachments at Bottom of Doc

Hi, Thanks again for responding :slight_smile:

Why do attachments lose their connection to the RT field (which still exists on the form). The attachments still display in the RT field but with a Note Item Not Found error. This doesn’t happen on all documents which is why I am so confused.

I still don’t understand how I can run an agent on all documents to see if there are documents at the bottom of the form? So, if I run an agent to check for the # of attachments via the EmbeddedObjects collection and if a # is returned, then does that mean I have attachments at the bottom of the form? If so, that just doesn’t make since to me.

My apologies, I’m just trying to make sure I understand.

Thanks again for your help in advance.