Thursday, December 19, 2013

Action button to set Date Value with Lotus Notes Formula Language

A quick and dirty way for doing this. No error checking, big assumptions about the input to the prompt being right.

1
2
3
4
5
nd := @Prompt([OKCANCELEDIT]; "Enter the New Date"; "YYYY/MM/DD."; @Today);
@If (nd ="";@Return("");"");
y := @Left (nd;"/");
m := @Left(@Right (nd;"/");"/");
d:= @right(@Right (nd;"/");"/");
1
2
FIELD DateFieldOnForm := @Date(@TextToNumber (y) ;@TextToNumber ( m)
;@TextToNumber ( d) )
The better, clean, way would be to use LotusScript and open a form in Dialog box mode, the form having a Calender tool on it.

No comments:

Post a Comment

Your feedback is always appreciated. I will try to reply to your queries as soon as time allows.Please don't spam,spam comments will be deleted upon reviews.