GetAllDocumentsByKey in the Web

Hi,

i’m trying to make a collection of documents using an web agent.

In this agent, i make a collection with a key but it always return 0 documents…

The view is sorted by the key that i use to make the collection.

Is this a limitation in the web?

Subject: RE: GetAllDocumentsByKey in the Web

No. Post your code.

Subject: RE: GetAllDocumentsByKey in the Web

Hi Stan

This is a extract of my code

Set webDoc = ses.DocumentContext

query_string = webDoc.Query_String_Decoded(0) ‘Obtenção dos parâmetros de pesquisa’

U = GetParms(query_string)

Set db = ses.GetDatabase(“”,“Dicionario.nsf”)

Set view = db.GetView(U(1))

strsearch = Trim$(U(2))

Set coll = view.GetAllDocumentsByKey(Cstr(strsearch), True)

If i do this in a notes client it returns the right number of documents. But if i do this in the web it returns always 0 documents…

Thanks

Subject: How is this code being run ?

Web Query OpenWeb Query save

as part of an agent?


and in any case …

I’m not too happy about

Set db = ses.GetDatabase(“”,“Dicionario.nsf”)

isn’t that trying to open the database on local?

maybe not a good thing on the domino server?

Subject: RE: How is this code being run ?

Hi Alan, the code runs on an agent.

This is the process:

I have an agent that generates a web page. On this page there some documents which have a link.

That link invokes another agent to get all the documents under a key to be showed in a page.

Is it confused? May be, but it was the only way i found to show a nice dinamically page to user.

When i invoke

Set db = ses.GetDatabase(“”,“Dicionario.nsf”)

i don’t have de server name and i don´t want to hardcode the name…

Thanks Alan