I received a message “@commands and other UI functions are not allowed in this context” when opening a domino form after making a simple change – in this case adding a button that would be used to launch another form creation. The create form button did not reference the form it was on – it would be used to create another form. The code on the button had been copied from another location which was working and the code itself was very simple as shown below
@Command([Compose];””;”Incident”) where incident is the name of the other form.
Removing the button (after noting that the code seemed to be missing on the on click event) and checking again showed the same error message. I then checked the design – only to find that the code had inadvertently been pasted into the form’s title property. It transpires that the code is only checked at runtime – hence the message when the form is opened.
Heres hoping that helps someone else.