9

I'm trying to use new Input and InputField with type attribute. I need to use the date or datetime type as follow:

<apex:input value="{!birthdayDate}" type="date" styleClass="select-box"/>

with corresponding controller:

public Date birthdayDate {
    get;
    set {
        System.debug('birthdayDate setter: ' + value);
        birthdayDate = value;
        currentAccount.PersonBirthdate = value;
    }
}

But when the user clears the field by clicking on the "x" button, the setter is not triggered and value cannot be reset.

I could use the inputField instead directly on PersonBithdate field, but I get an "Error: Invalid Date" when submitting the form.

FYI : I'm using API 29 (as requested by the Winter 14 release notes) for this files.

Thanks for your help.

4

See http://boards.developerforce.com/t5/Visualforce-Development/New-HTML5-Apex-Input-issue/m-p/698847#M70703. Fixed in next release. Thank you.

0

i think the type of PersonBithdate is not date,so you see the error when submitting the form.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.