salesforce - How to find if an apex:inputField is disabled -


from visualforce controller, how can find if dependent pick-list inputfield disabled?

there not seem accessible 'disabled' property field. creating validation make sure fields on visualforce page filled out. not want validation on dependent pick-list when there no values select, , in disabled state.

if dependent picklist required , no values available based on controlling field value, users can save record without entering value. record saved no value field. dependent picklist considerations

if required jest on page:

public boolean statedisabled {get;set;}   <apex:inputcheckbox styleclass="statedisabled" style="display:none"  value="{!statedisabled}" /> <div>  <apex:inputfield value="{!con.mailing_country__c}" onblur="statedisabled();" /> </div>               <div class="state">   <apex:inputfield value="{!con.mailing_state_province__c}" onchange="statedisabled()"  /> /div> <script>     function statedisabled(){         $(".statedisabled").attr('checked',true);         if(!$(".state select").attr('disabled')){             $(".statedisabled").attr('checked',false);         }     } </script> 

Comments

Popular posts from this blog

blackberry 10 - how to add multiple markers on the google map just by url? -

php - guestbook returning database data to flash -

delphi - Dynamic file type icon -