I'm trying to create a progress bar with a programmed table in the "Switcher mail form." In the code, when I want to set a hide field to calculate the value of the table in sub queryopen, the program shows the message "variable object not set."
By submitting your personal information, you agree that TechTarget and its partners may contact you regarding relevant content, products and special offers.
Sub Queryopen(Source As Notesuidocument, Mode As Integer, Isnewdoc As Variant, Continue As Variant) Dim doc As notesDocument Set doc = source.document doc.calculo = "1" End Sub
I know that I should use "If NOT Isnewdoc," but I have to set the field "calculo" anyway. Do you have an example to set a field in queryopen?
The QueryOpen event happens before the Lotus Notes document is opened. In QueryOpen, the source.document is not yet set. You should use the PostOpen or OnLoad events to set a field value. These occur after the document loads but before the user has access to the fields.
Do you have comments on this Ask the Expert Q&A? Let us know.
Dig Deeper on Lotus Notes Domino Agents
Related Q&A from Brian Mahoney
Find out what types of calculations can be computed for a column in a Lotus Notes view and the best way to go about it with this expert response.continue reading
Find out why you can't use Formula language to include a doclink to a specific Lotus Notes view or database and need to use LotusScript instead.continue reading
Discover the reasons behind a Notes/Domino admistrator having trouble with disabled options in the "customize this view" section of his Lotus Notes ...continue reading
Have a question for an expert?
Please add a title for your question
Get answers from a TechTarget expert on whatever's puzzling you.