Skip to Content
avatar image
Former Member

adobe date format

Hi

i have binded an atrribute of type date to date/time field (DD-MMM-YYYY).if user enters any other formats like 1234,or an invalid date,then he click on submit button, error msg is displaying saying that "Enter the value in the format 1987- 11-25." instead of 25-NOV-1987 .please can u send the date validation code .

Thanks

rahul

Edited by: rahul kumar on Dec 6, 2008 7:33 AM

Edited by: rahul kumar on Dec 6, 2008 7:33 AM

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

2 Answers

  • avatar image
    Former Member
    Dec 06, 2008 at 09:57 AM

    Hi -

    Refer the thread [SAP Interactive Forms by Adobe;

    See, if this help you.

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Dec 06, 2008 at 09:59 AM

    Try this. May be it would help.

    You can write formcalc script on DATE field in 'preSubmit' event to validate the specified format and a message to pop up.

    FormCalc script -

    if (data.subform#.DATE.format != 'specified format')

    then

    xfa.host.messageBox("Please enter DATE in YYYY-MM-DD format only")

    endif

    As you have already specified the DATE format in paletts -> objects -> bindings, it will not accept any other format entered. The above script will let a message to pop up displaying the same message.

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi Vishal

      Thanks for u reply, my problem is when ever pop up opens saying that Please enter invalid date when user clicks on OK button of pop up window then that invalid value in date/time field should become Null,can u please tell me how to write code for it

      Thanks

      kishore