Save Updated field in OpenDocument

Posted on 2005-05-05
Last Modified: 2013-12-18
This is my problem.  I have an embedded view (web by the way) that displays current applicants for our company.  Clicking their name opens their application.  The link is the id + ?OpenDocument.  I would like to have the ability to change a field on their application easily.  There is a status field, contains some options for their application.  I can change the value easily enough, but I cannot save the form once its changed.  I get this error:

HTTP Web Server: Lotus Notes Exception - @Function is not valid in this context

So I take it to mean I can't use @Command([FileSave]) in this situation.  Is there a way around it without opening it with ?EditDocument  ?
Question by:DawG25
    LVL 13

    Expert Comment

    You make it sound as if you are opening the document in read-mode ("?opendocument"), not edit-mode ("?editdocument").
    In readmode @Command([FileSave]) isn't a valid command.
    But I can't see how you get to edit fields in readmode!?

    Author Comment

    Maybe it doesn't actually get changed.  Is there a way I can change it.  And yes. I use ?OpenDocument.
    LVL 13

    Accepted Solution

    Sorry, I have overread your "?opendocument" statement in the question itself.
    That means your document is in read-mode, where @Command([FileSave]) doesn't apply. Designer help says it all:
    "A document must be open in edit mode"

    How did you set this status field in editmode? Did you simply generate it in HTML? Bear in mind that Domino is not expecting you to send data in this situation!

    Now to get around this issue, I can think of a few approaches. Forcing the document in edit-mode is the most common one of course.

    Second, you could try @SetDocField to write the field to the doc's back-end, based on its unique id.

    Either way, you'd need at least author access to the document.

    As an alternative, you might trigger an agent (through URL). That way -if I remember well- it's not YOU applying the change, but the agent's signer (thus the one requiring author acdcess to the doc).

    If that's causing trouble, you could decide to go for a dirty appoach: generate responses to the documents and have a scheduled agent to move some of the fields from the response to its parent and delete the response.

    In fact all you need is to understand why an error occurs and be creative in finding a way around.

    Author Comment

    @SetDocField worked great.  Thank you.

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Do You Know the 4 Main Threat Actor Types?

    Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

    Suggested Solutions

    For Desktop Techs: How to retain a user's Notes configuration data when swapping out the end user's computer. (Assuming that you are not upgrading to a completely different version of Notes client) All you need to do is: 1) install Notes o…
    Problem "Can you help me recover my changes?  I double-clicked the attachment, made changes, and then hit Save before closing it.  But when I try to re-open it, my changes are missing!"    Solution This solution opens the Outlook Secure Temp Fold…
    Migrating to Microsoft Office 365 is becoming increasingly popular for organizations both large and small. If you have made the leap to Microsoft’s cloud platform, you know that you will need to create a corporate email signature for your Office 365…
    Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

    737 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    20 Experts available now in Live!

    Get 1:1 Help Now