Salesforce Certified Application Architect

Friday 24 March 2017

Validation for disbale and enable in VF page











<apex:page >    
  <apex:form>
   <apex:pageblock title="Customer Information" id="PBBlockTemp">
    <apex:pageBlockSection title="Basic Details" id="PBBlockSectionTemp">
       <script>
      
            /* Start After save button disabled option won't be changed 
             document.onreadystatechange = function(){
                 if(document.readyState === 'complete'){
                     if(document.getElementById('{!$Component.PBBlockTemp.Tempoccupation}').value == 'false'){
                         document.getElementById('{!$Component.PBBlockTemp.PBBlockSectionTemp.OtherBusinesstemp}').disabled = false;
                        }
                     else{
                         document.getElementById('{!$Component.PBBlockTemp.PBBlockSectionTemp.OtherBusinesstemp}').disabled = true ;
                        }
                    }
                }
              End After save button disabled option won't be changed  */
             
        /* Start Once Changed filed value other field will be disabled     
        function othersUpdateValue(input) {   
               
            if(input.value == 'Others'){
                document.getElementById('{!$Component.PBBlockTemp.PBBlockSectionTemp.OtherBusinesstemp}').disabled = false;
                document.getElementById('{!$Component.PBBlockTemp.Tempoccupation}').value = false;
            }
       
        else{
                 document.getElementById('{!$Component.PBBlockTemp.PBBlockSectionTemp.OtherBusinesstemp}').disabled = true;
                 document.getElementById('{!$Component.PBBlockTemp.Tempoccupation}').value = true;
            }
        }
        </script>
       
         <apex:inputField label="Test Type" value="{!lead.Tset_Type__c}" onchange="othersUpdateValue(this);"/>
         <apex:inputField label="OccuTest" value="{!lead.Others_Test}" Id="OtherBusinesstemp"/>
         End Once Changed filed value other field will be disabled */
       
         After Button
       
        <apex:inputHidden value="{!Tempoccupation}" id="Tempoccupation"/>
       
    </apex:form>
     </apex:page >   
          Controller Property
          public boolean Tempoccupation {get;set;}

Salesforce Certified Application Architect & Certified Data Architecture and Management Designer Exam

How to pass Salesforce Certified Data Architecture and Management Designer Exam This exam was 1st architect exam for me. Its not that muc...