Search code examples
buttonlotus-notesformulalotusscriptlotus-formula

Change the caption of button in Lotus Notes


How can I change the caption of a button using LotusScript/Formula?


Solution

  • What Ken says is true, but you can change button labels using JavaScript in the Notes client. You'll need to go to the <HTML> tab of the button properties and give the button a name value (an id value works as well in later versions), then you can use

    document.forms[0].ButtonHTMLName.value = "New Caption";
    

    or

    document.forms[0].elements["ButtonHTMLName"].value = "New Caption";
    

    Either can be triggered from any number of client events in Notes version 6 or higher using client-side or common JavaScript.