I am working on setting a default value for a feild in a view I have completed the web side of things but I was instructed to go into the postopen form and write something like if isnewdoc then default the daysopen field to a value of "1". this is what i tried and it didn't work any advice on how to do this.
If uidoc.IsNewdoc Then Set doc = uidoc.Document Call doc.ReplaceItemValue("daysopen","1")
Call doc.Save(True, False) Set doc = view.GetNextDocument(doc)
End If
How I could use postopen and put code in there so that "daysopen" would get a default value of 1. I originally did an if statement with @today in the field but that made it run far to slow. So I wrote an agent and now it runs faster it just doesn’t get the first day "1" because the agent only runs once a day so until it runs it is blank. I need a code that would set the default in the client postopen that so it doesn't slow it down. Any Ideas?
Please help me fix this.
PS. I am using a form for this and need to write code into the postopen form to get the default vavle
BruceWayne: the poster, AMcAuley3, says he has "...completed the web side of things...". It sounds like he is developing something for a browser, not the Notes client. Would the lotusscript postopen event evaluate from the web? I don't remember ever using a postopen for a web app. I don't have time to test it now. If he really wants to use script, I think he could write an agent, then call it in the webqueryopen. What do you think?
Mmmm :-
You're right again Brooklynegg !
Postopen doesn't trigger in web. But webqueryopen will do the trick.
Sorry, I did not see the "Web Side Of Things" ...
Discuss This Question: 3  Replies