Code: Say you have a computed field called [TotalAmount], that you wish to display and update from a button or action in the browser. Insert the following pass-through HTML text around the computed field:
<INPUT NAME = "TotalAmount" VALUE = "[TotalAmount]" "READONLY">
where everything is text except for the actual computed field which is represented as [TotalAmount]. Make sure you highlight the entire line and use the Text dropdown to mark it as Pass-Through HTML. Also make sure you do not check the "Generate HTML for all fields" on the Form Properties dialogue.
document.forms.TotalAmount.value= parseInt(document.forms.TotalAmount.value) + 1;
The revised value of TotalAmount is passed back to notes and can also be accessed by a WebQuerySave routine.
Note - Since you cannot check the "Generate HTML for all fields" option, you can simulate this action in the browser for hidden fields> using pass-through HTML of the form:
<INPUT NAME = "MField" VALUE = "[MField]" TYPE= "hidden">
This is the code that Domino would generate for hidden fields if the the "Generate HTML for all fields" option were enabled.
Note - If your application is to be used by both Web browsers and (R4.6 or later) Notes clients, you may need to implement this as a Web-only form. To do this, copy your original Notes form and modify the copy for use by the Web client. The two versions of the form should have different names and the same alias and hidden from either Web users or Notes clients as appropriate. For example, if your original form is called "Invoice", rename it to "UserInvoice-Notes | Invoice" copy it and rename the copy as "User Invoice-Web | Invoice". From the Designer Forms view, right click on each form select Design Properties, and check the appropriate "Hide Design Element from" check box. Now you can make the appropriate changes on the Web-only form without affecting the Notes users.