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

Data Binding

Hi

I have a dropdownbyKey Country UIElement. I have created a simpletype called CountryValue and assigned some constant values to it. In the view context i have created a ValueNode called Countrynode and then below that i have created a value attribute called Countryattribute.

If i bind the Country UIElement to this CountryAttribute and try to run the program, The dropDownbybox is disabled and i am not able to Use it. Can anyone suggest what could be the problem.

ravi

Add a comment
10|10000 characters needed characters exceeded

Related questions

2 Answers

  • author's profile photo Former Member
    Former Member
    Posted on Jul 23, 2004 at 04:59 PM

    First, let's have a look at the Javadoc:

    /**
     * Web Dynpro AbstractDropDownByKey API.
     *
     * Abstract base class of drop-down list classes with key based context binding.
     * Represents a one-from-many selection visualized by a text field, a button and a drop-down list.
     * The selected value is displayed in the text field, the list of all selectable values is displayed
     * in the drop-down list which appears when the button is pressed.
     * <p>
     * <strong>Data binding:</strong>
     * <br>
     * The set of selectable keys, displayed texts and the selected key are retrieved from a context.
     * This context must provide an attribute <code>y</code> of a type having a value set.
     * The selectable keys of the drop-down list are the keys of this value set,
     * the displayed texts are the corresponding values.
     * The currently selected key is the current value of the attribute <code>y</code>.
     * <p>
     * The property <code>selectedKey</code> must be bound to the attribute <code>y</code>.
     *
     * <p>This type can be called by applications using Web Dynpro, but DO NOT EXTEND OR IMPLEMENT IT!</p>
     *
     * @author SAP
     * @see com.sap.dictionary.runtime.ISimpleType
     * @see com.sap.typeservices.ISimpleValueSet
     * @SAPWebDynproPart 2
     */
    

    What is the value node in your code good for?

    Armin

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Jul 23, 2004 at 11:16 PM

    Hi Ravi, you are using the wrong type of dropdown. From your setup, you need to make a dropDownByIndex type dropdown, then you will see all the changes populated.

    The difference is explained more clearly here:

    http://help.sap.com/saphelp_nw04/helpdata/en/74/450e8af57065468e88e4b86de47e4b/content.htm

    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.