Skip to Content
author's profile photo Former Member
Former Member

input field type date

Hello All,

I have two questions regarding an input field bound to a value attribute of type date.

When I check for null on the input field using messages and i set message type as error , i cannot enter another date in the input field. However if I set the message type as standard it allows me.How can i fix this?

Also how do I perform action after a date is chosen? I created an action ONENTER but the code within the method does not run


Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

2 Answers

  • Posted on Sep 24, 2005 at 03:55 AM

    Hi Vijay,

    The ONENTER event is fired when you press the ENTER key at your keyboard.

    There is no event fired when a control looses focus. This is what you would need. This is probably not fired because it would dramatically slow down the performance of your application if with every loose focus a server roundtrip would be triggered.

    In regular J2EE applications this is done by JavaScript but this is not possible in Web Dynpro.

    You can emulate such a behavior by using the wdDoBeforeNavigation method of your component controller. This method is called with each server roundtrip. In this method you can compare the new date with the old date (if stored anywhere in the context) and react in any way to the change.



    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Sep 26, 2005 at 08:18 AM

    Hi Vijay,

    1) I have no help to offer for your first problem. Even I am very much interested to know why that happens.

    2) Regarding your second question, In webdynpro we cannot define our own listeners for a UI element. Instead we have to use only those events given by SAP itself. For input field, only one such event is already provided - 'onEnter'. So If you want to capture the date entered through an input field and show it in a text view, you either have to force the user to press Enter or make use of a button or LinkToAction for that. Using DateNavigator instead of InputField would provide few more events like 'onStartDateChange' for this purpose.

    Hope this helps,

    Best Regards,


    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.