How can validate rich text field using @formulat? I am enforce to enter data when user clicks on a Button but does validat the rich text field. BriTitle is rich text field.
@If(@Text(BriTitle)= “”; @Do(@Command([EditGotoField];“BriTitle”);@Return(@Prompt([Ok];“Required:”;“You must enter data.”)));“”);
You don’t say where you put this formula. To stop the document from saving, it would have to be in an input validation formula (of some other field). But I don’t think you can use an @Command in that context.
It would be better to do your validation using LotusScript in the Querysave event. You could use NotesUIDocument.FieldGetText if you’re only interested in the text – checking on other things is more complicated.
On the web, you can use JavaScript for validation in the onsubmit event. See how the automatically generated JavaScript code in the HTML reads data from the rich text field to submit it with the document. Do that yourself to see what’s in the rich text.