ViewNav not finding documents

This has to be some kind of brain-fart or something, but I do this all the time and it isn’t working for me today.

I have the following code:

Set vwProject = dbProject.GetView(“ProjectWebLookup”)

If vwProject Is Nothing Then

Error 1501, "Could not find project view"

Else

Msgbox "Got view ProjectWebLookup with [" + Cstr(vwProject.EntryCount) + "] documents."

End If

Set nvnProject = vwProject.CreateViewNav

If nvnProject Is Nothing Then

Error 1501, "Could not create view navigator"

Else

Msgbox "Got view nav with [" + Cstr(nvnProject.Count) + "] entries."

End If

And it is returning the following to the log:

Agent message: Got view ProjectWebLookup with [99] documents.

Agent message: Got view nav with [0] entries.

What could be causing this?

Subject: ViewNav not finding documents

It must be something in your view definition, since your exact code works perfectly in my application.

Has it to do with access rights of the underlying documents?

Subject: RE: ViewNav not finding documents

You are absolutely right, thank you! I was accessing an external database and didn’t realize the documents in it were all protected by readers fields. Thanks for catching that.