computed field value in xpages

lotus-domino, lotus-notes, xpages

Solution

You're missing the parentheses in your calls to getValue(). By omitting these, you're returning a pointer to the getValue method of the component, not the result of invoking that method. Change each reference to getValue to getValue(), and you'll get a different result.

Problem

I am trying to update a computed fields value on click of a button with a value of a edit box + its own value. Code written on button: here i put value of edit box in scope variable and make edit box blank. comment_te is the name of edit box ``` requestScope.put("commentValue", getComponent("comments_te").getValue); getComponent("comments_te").setValue(""); ``` Code written for value of computed field: comments is the name of computed field ``` getComponent("comments").getValue + "\n" + requestScope.get("commentValue") ``` But I get the output is: 0 com.ibm.xsp.component.xp.XspInputText@65426542 Please help me with this.

Original source