on 09-07-2010 1:08 PM
Hi,
How do i show the short text of a domain value instead of the Fix value key in an input field.
Thanks.
Regards,
Morten
Thanks for all replies
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Consider using a DropDownByKey instead of an InputField. The DDLB will automatically show the value text instead of the value key (yet contain the key in the bound context attribute). The inputField on the other hand will always only display whatever value is contained in the bound context attribute.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Thomas,
Thanks for your reply.
Yes i am aware that the functionality is given by the DropDownByKey. My problem is that the fields are build runtime by a dynamic customizing table. This table does not contain the option to create other than InputFields at present time. A solution could be to extend this table with the option to select UI element type (InputField, DropDownByKey etc.) Before implementing this I was looking for a more simple solution. Do you see any?
Thanks,
Regards,
Morten
>
> other option is to to code in modifyview, retrieve the domain fixed value text for the key entered and bind the value to the same field
Keep in mind that if you do so, you are overwriting the key value in the attribute. When you save this data back to the underlying data object you would have to change back from the text to the key. Keep in mind that the text doesn't necessarily mean you have a 1:1 match with the key. It is possible to have 2 or more keys with the same text description. You must be careful taking this approach.
Instead you might consider displaying the text in a separate field next to the inputField. The problem is that the text won't update until the next server event. This can mean the text is out of sync with the value in the inputField.
Best approach from a usability standpoint for the end user is a DDLB.
User | Count |
---|---|
90 | |
10 | |
10 | |
10 | |
7 | |
7 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.