You need to sign in to do that
Don't have an account?

Bug or feature ?
I created visualforce page for creating my custom object. I wanted to fill some date after user insert a part of it:
<apex:inputField value="{!Costs_Agreement__c.Type_of_cost__c}"> <apex:actionSupport event="onchange" action="{!valuesFromConfigRecord}" rerender="field" status="counterStatus"/> </apex:inputField> <apex:actionStatus id="counterStatus" startText=" (Retriving data...)" />
If user change data in input field, two fields of object Costs_Agreement__c will be updated and input fields whit them should be refreshed.
<apex:outputPanel id="field"> <apex:inputField value="{!Costs_Agreement__c.MOR_account__c}"/> <apex:inputField value="{!Costs_Agreement__c.Cost_account__c}"/> </apex:outputPanel>
But if i have on the same page an inputfield whit value from my object that is required and it is empty fields wont be refreshed. If i put any data in this required field then everything works fine.
Should it work that way ? What if i would like to dynamical insert some data into required field ?
This is correct behaviour - you have required fields elsewhere on your page, validation takes place before the controller method is invoked, so you receive an error.
It sounds like you want to use the ActionRegion component - this allows only a subset of fields to be sent back to the controller, and required fields outside of the ActionRegion won't interfere.
There's more information at: http://www.salesforce.com/us/developer/docs/cookbook/Content/vf_dynamic_page_update.ht