You need to sign in to do that
Don't have an account?
The SFDC Matrix
How to use single inputTextField to Create a Calculator with Controller Class in Visual Force?
For Example to create calculator i want to use only one
<apex:page controller="classname">
<apex:inputText value="somevalue" action="{!someaction}"/>
</apex:page>
With this single inputText and On clicking the button , the values in the text field should be passed to the controller class and generates output.
<apex:page controller="classname">
<apex:inputText value="somevalue" action="{!someaction}"/>
</apex:page>
With this single inputText and On clicking the button , the values in the text field should be passed to the controller class and generates output.
Controller: VF Page:
The VF page has an inputText that is bound to the controller's inputNumber variable. When the button is clicked, the addOne() method is executed and the inputNumber is incremented by 1. The resulting number is assigned to the outputNumber variable and displayed back on the VF page.
Hope that helps,
Clint