function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Karna_ShivaKarna_Shiva 

How to populate one inputfield value from other inputfield value based on other inputfield condition in visualforce page

How to populate one inputfield value from other inputfield value based on other inputfield condition in visualforce page

Scennarion:

First Year , Deal TCV, Deal duration.

if Deal durations is lessthan 12 then vf page auto populate the Deal TCV value on First year field.

If Deal_duration <=12 then First year = Deal TCV
harsha__charsha__c
Hi Shiva,

Check this way out..
 
<apex:inputField value="{!IF(Deal_Duration__c <=12, Deal_TCV__c, First_Year__c)}"/>

This should work..

- Harsha
Karna_ShivaKarna_Shiva
Hi harsha, thanks for your reply.

this will work for only exsisting records,i want for new records,generally we will pass value for deal tcv and duration that time javascript or jquery suppose to check condition and then it has to populate value on First Year.

Regards,
Karna.