1
votes

Is there a way I can get the field value of a document if I know the document UNID?

I have the following code:

var a = database.getDocumentByUNID(sessionScope.unid);
  • sessionScope.unid contains the documentUNID.

I can't see any methods avaible if I do a. . Is there something wrong?

1

1 Answers

5
votes

SSJS does not provide typeahead unless you specifically cast variables as the class you wish to use. So to get typeahead you need to use:

var a:NotesDocument = database.getDocumentByUNID(sessionScope.unid);