Changes to NotesDocument.IsValid?

I have noticed lately that the functionality of the NotesDocument.IsValid has changed.

I have an application where I loop over response documents, looking for ones that belong to the current user.

Each response document is secured using a READERS field.

When a user runs the code, doc.Responses contains all responses regardless of whether the user actually has access to the documents.

Inside the response loop, I check NotesDocument.IsValid to determine whether the user has access to the document. This used to work fine, but now IsValid works more like it is documented to work. That is, it only identifies whether the document is a deletion stub or not.

This is unfortunate for me since I now have to remember everywhere I have ever used IsValid to check for document access. And find a workaround. Currently, I am checking NotesDocument.Size, and if it’s zero, I know that the document should be skipped. There really should be a supported method for determining whether the current (or any) user has access to a document. Something like IsReader([user_name]) or IsAuthor([user_name]) would be great!

It is also very confusing having two methods that appear identical in the documentation except for a minor difference in verbiage…

NotesDocument.IsValid

Indicates whether a Document object represents an existing document (not a deletion stub) initially.

NotesDocument.IsDeleted

Indicates whether a Document object represents an existing document (not a deletion stub) on an ongoing basis.

What the heck! Either a document is deleted or it isn’t. What’s this “initially” vs “on an ongoing basis” junk?

Anyway, enough of my rantings.

Any thoughts on this? At the very least, I would have expected a note in the documentation listing the change in behavior.

Subject: Changes to NotesDocument.IsValid?

The help documents are very confusing regarding IsValid and IsDeleted.

“initially” for Is valid means when you actually get the document in the code, ie when you set the notesdocument to a document in the database.

“on an ongoing basis” means that after you have set the notesdocument above you can check if somebody has deleted it while you were working with it.

I hope that clears it up a bit, unfortunately i do not know of a way to check for the author or reader access.