Skip to Content
avatar image
Former Member

Konversionproblem with DropDownByKey

Hi Experts,

I have a problem when dynamically assign values to a DropDownByKey List. It works fine when I use an defined Data-Element, but when I assign the UI-Element to a contect, that contains a WDY_KEY_VALUE_TABLE datatype (which should be filled correctly), then I get the following error:

Hinweis

Folgender Fehlertext wurde im System ER3 prozessiert: Konvertierung von Typ h nach Typ g nicht unterstützt

Der Fehler trat auf dem Applikationsserver h01sape_ER3_00 und im Workprozess 3 auf.

Die Abbruchart war: RABAX_STATE

Die ABAP-Aufrufhierarchie war:

Method: IF_WD_CONTEXT_ELEMENT~GET_ATTRIBUTE of program CL_WDR_CONTEXT_ELEMENT========CP

Method: GET_ATTRIBUTE_INTERNAL of program CL_WDR_VIEW_ELEMENT_ADAPTER===CP

Method: IF_WDR_VIEW_ELEMENT_ADAPTER~SET_CONTENT of program /1WDA/L0STANDARD==============CP

Method: IF_WDR_VIEW_ELEMENT_ADAPTER~SET_CONTENT of program /1WDA/L8STANDARD==============CP

Method: IF_WDR_VIEW_ELEMENT_ADAPTER~SET_CONTENT of program /1WDA/L8STANDARD==============CP

Method: IF_WDR_VIEW_ELEMENT_ADAPTER~SET_CONTENT of program /1WDA/L8STANDARD==============CP

Method: IF_WDR_VIEW_ELEMENT_ADAPTER~SET_CONTENT of program /1WDA/L7STANDARD==============CP

Method: IF_WDR_VIEW_ELEMENT_ADAPTER~SET_CONTENT of program /1WDA/L8STANDARD==============CP

Method: IF_WDR_VIEW_ELEMENT_ADAPTER~SET_CONTENT of program /1WDA/L8STANDARD==============CP

Method: IF_WDR_VIEW_ELEMENT_ADAPTER~SET_CONTENT of program /1WDA/L7STANDARD==============CP

That mean's conversion from type h to type g is not supportet. I have no idea, to what types this message references.

I get the same message, when the valu set is not filled at all. I'm somekind of lost and would appreciate a little hint 😊

Regards

Torsten

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

3 Answers

  • Best Answer
    avatar image
    Former Member
    Aug 07, 2007 at 06:34 AM

    Hi,

    please try to bind your value set to a character based datatype,

    the key of the value set will need to be a character based data-element or

    an existing one eg z_datatype with char 5

    pick something to your likings, that will be able to contain your value-set key,

    the texts will be loaded as they should

    grtz,

    Koen

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi Experts,

      my first problem here was, that I usually use if_context_node type and the set_attribute methode to set values to my context. So, I was quiet confused by the use of if_context_node_info and the set_attribute_value_set methode. Then, there was no hint, that this method exports anything else, than the valueset. So the hint to use a String in case of WDY_KEY_VALUE_TABLE was the right clue, thank you 😊 .

      Regards

      Torsten

  • avatar image
    Former Member
    Aug 07, 2007 at 08:27 AM

    Hi Torsten,

    Instead of using the type WDY_KEY_VALUE_TABLE, use a context attribute of type WDR_CONTEXT_ATTR_VALUE_LIST. This is the type that is generally used for drop down by key. I think this should solve the problem.

    Regards

    Nithya

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Aug 07, 2007 at 08:43 AM

    Hi Torsten,

    As both the component of the structure WDY_KEY_VALUE the line type for WDY_KEY_VALUE_TABLE are of type string , the values to be assigned should be of type char , try to assign key and value of character type .

    Regard's

    Amol

    Add comment
    10|10000 characters needed characters exceeded