on 08-03-2012 9:26 AM
I have created a view in which user enters his/her logon credentials . I want that if he enters wrong data the caption saying "Wrong ID/Password" gets enabled. How can i do that by writing code in Webdynpro event. Kindly Help.
Hi Varun,
Caption UI element has 'ENABLED' property with which you can play as you wish.
1. Create an attribute of type WDY_BOOLEAN
2. Bind this to the ENABLED property of caption
3. Write code to enable/disable the attribute
But for your scenario reporting an error message should be better than enabling a caption.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
And how to change the text of caption via coding. I tried it by binding the text to a context attribute of type string but it isn't changing.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Varun,
there is no other way to validate entered credentials except onEnter of usrid input / password input or Login/Submit button.
am not sure is there any onKeyPress or any other events exists for this criteria.
For caption, just create a Group and you bind the context attribute to text property of Caption of group, then you can change text according to your requirement.
else, you can directly report error message.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
23 | |
11 | |
9 | |
8 | |
5 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.