Dropdown by key problem

Hi
I am using drop down by key UI element in my WD4A application . When I run it a <b>short dump</b> occur stating that "<b>The lead selection has not been set</b>".
I have created a contect in ComponentController and written following code in INIT method of component controller.
The node name is TEST and it has a attribute "Value", which is binded with UI element. The lead selection property od context node is checked.
DATA:
    node_test                           TYPE REF TO if_wd_context_node,
    ls_node                             TYPE REF TO if_wd_context_node_info,
    ls_value                            TYPE wdr_context_attr_value,
    lt_value                            TYPE TABLE OF wdr_context_attr_value.
navigate from <CONTEXT> to <TEST> via lead selection
node_test = wd_context->get_child_node( 'TEST' ).
ls_node = node_test->get_node_info( ).
  ls_value-value = '1'.
  ls_value-text  = 'Testig'.
  INSERT ls_value inTO TABLE lt_value.
  CALL METHOD ls_node->set_attribute_value_set
    EXPORTING
      name      = 'VALUE'
      value_set = lt_value.
Regards
Vishal kapoor

Hi Vishal,
Change your TEST node properties like below.
Cardinality                              :  1 to 1
Selection                                :  0 to 1
Initialization Lead Selection      :  X
Singleton                                : X
I hope it will help you.
Thanks & Regards,
Anil

Similar Messages

  • Follow up to my Luma Key problem

    Hi again,
    Tom has answered to my Luma Key problem of bad quality by recomending me to put the oval form under my clip instead from above, and it worked verz well.
    But now I have another problem, I want now my oval to cross disolve to have the full scene that is now under to come gradually fully on screen. I have a cross disolve at the begining and at the end of the oval. Its fine for the oval to come gradually from full black screen to an oval with behind the 2nd scene, but when it shall starts to disolve, nothing happens. I also try with the pen, adding points and then pulling down in order to have the oval clip gradually dissolving, but nothing works ! Any clue ?
    Thanks,
    Nic

    Nicolas,
    One way to do this is:
    - Oval on V1
    - Clip1 on V2 with Composite Mode > Travel Matte Luma
    - Clip1 also on V3. Change it's opacity so it is 0 until the required number of frames before the end of the Oval. Then increase it's opacity to 100 at the end of the Oval.
    There might be a more efficient way to do this.

  • How to change the Text of Dropdown by Key Dynamically thats coming from RFC

    HI All,
    I need an urgent help . I have a parameter coming from RFC -> YYTEXT with a value Range and I am binding this parameter in my DROPDOWN BY KEY .Now I have a requirement that two values coming from this parameter i need to change it
    .Can you please tell me how to get the values from this YYTEXT attribute which is in NODE1 and then set the two new texts to this attribute so that it shows different text in the droodown .
    Thank you in Advance .
    Naaz

    Will appreciate any comments on the question ?

  • Handle standard dropdown by key field dynamically.

    Hi Experts ,
    I'm enhancing dropdown by key field in web-dynpro from editable to read only state.
    The default value is already set in init method.
    but i am not able to handle it dynamically, purpose is that user can not change the drop down in create/edit mode.
    Already tried below code but getting errors:
    data: lo_inp type ref to cl_wd_DROPDOWN_BY_KEY.
    lo_inp ?= view->get_element( 'FOLLOW_ON_DOC_KEY' ).
    call method lo_inp->set_read_only( exporting  value =  abap_true ).
    please help.

    Hi Purushottam,
    You code looks okay.
    What kind of error are you getting? Please share the details.
    Regards,
    Rama

  • DropDown by Key and Row Repeater

    Hello,
    I 've build a form inside a rowrepeater, inside the form there are several empty drop down by key.
    The key value table of each dropdown by key belong to the selected country grouping (an input field with search help inside the form).
    OnEnter event of the molga field, I call a BL to fill the key value table and get the index of the form (regarding to the dataprovider of my row repeater).
    Here is the structure of my context:
    CONTEXT _
                     |_CTX_COLL (0:N)
                                  |_CTX_DROPDOWN (1:1)
    * --- GET MOLGA --- *
    * navigate from <CONTEXT> to <CTX_COLL> via lead selection
      lo_nd_ctx_coll = wd_context->get_child_node( name = wd_this->wdctx_ctx_coll ).
      lo_nd_ctx_coll->get_static_attributes_table( importing table = lt_ctx_coll ).
      read table lt_ctx_coll into ls_ctx_coll index iv_index.
      lv_molga = ls_ctx_coll-country.
    * --- GET DROPDOWN NODE INDEX REFERENCE --- *
      lv_idx_str = iv_index.
      concatenate 'CTX_COLL.'
                  lv_idx_str
                  '.CTX_DROPDOWN' into lv_path.
      condense lv_path no-gaps.
    * navigate from <CONTEXT> to <CTX_DROPDOWN> via index selection
      lo_nd_ctx_dropdown = wd_context->path_get_node( path = lv_path ).
      lr_node_info = lo_nd_ctx_dropdown->get_node_info( ).
    * --- SET DROPDOWN --- *
      lt_value_set = wd_assist->get_priority( lv_molga ).
    * set values (table) to context attribute
      lr_node_info->set_attribute_value_set(
       name = `PRIORITY`
       value_set = lt_value_set

    well ehrr
    I see two completely different implementations
    the context dropdown must be used with a drop down by INDEX
    the value set must be used wth a dropdown by KEY
    as you have a ddk, it uses the value set
    furthermore, you set the value set on the dropdown context
    try the index one
    I'm not sure what you are trying to do, but try the following option
    you have a node in which your dropdown field resides
    make a subnode with the values for that field
    fill the subnode depending on the selected country (don't forget to invalidate the node when the country changes)
    bind a ddi to the dropdown values in the node
    the value set is defined on node level, not on element level
    so setting a different value set per element won't work i'm afraid
    correct me if i'm rong
    Edited by: Tom Van Doorslaer on Apr 3, 2009 3:48 PM

  • Change lead selection in dropdown by key

    Hi,
    I am using dropdown by key in one of my application.
    I am getting some values by calling a FM.FM
    returning me a table . My context for the dropdown is from the structure of the table.
    --drpplan(node)
      ---code -(attribute)
      -- desc-(attribute)
    I am binding the values from the table to the node info and to code attribute to populate the dropdown by key.
    It is working fine.
    My requirement is when user selects some thing from dropdown corresponding description should show in a textview.
    If I used a dropdown by key I know I dnt have write any code for this as the lead selection autometically changes. How to do this in dropdown by key.
    I konw I can write in the onselect method, call the FM again and read the table  with sected key and set the value.
    But in this approch I am calling FM twice hitting the db again.
    Is there any other way out. ?
    Thanks,
    Prosun

    u can store the data in an internal table when the FM is 1st called.
    And retrieve the describtion at  selection event.

  • I am running CC on Windows 7. My Control key is sticking only in PPS. It is not a sticky key problem

    I am running CC on Windows 7. My Control key is sticking only in PPS. It is not a sticky key problem and I am not running any similar program.

    yes, photoshop.
    Col. 3:17
    Sam Collins

  • 'Keys' problem when trying to re install 10.2 on Power Mac G4

    Have had my Power Mac G4 wiped clean prior to selling and am now trying to reinstall 10.2.
    Install disc one reached the end of its loading process and then froze.
    Install disc two did not respond when loaded.
    Put install disc one back in while holding down 'C' key. Started to install but soon stopped.
    Went to Disc First Aid > verify disc > 'keys out of order HD need repairing'.
    Clicked 'repair disc' and indicated 'repair complete'.
    Returned to 'verify disc' > HD needs repairing, key length too short.
    Repaired once more, keys still out of order.
    Removed Install disc one and loaded Disc Warrior.
    Speed inhibited by malfunction stage 5 when rebuilding directory.
    So with no full operating system loaded, how do we progress?

    John:
    "Keys problems" are directory issues which, if not repairable by Disk Utility need a third party package like Tech Tool Pro, DriveGenius, or Disk Warrior. However, in some cases the disk hardware may be damaged or the HDD may have failed and unable to hold the format. When in DU check the SMART status. Even if the SMART Status is Verified and the HDD is more than 3 years old you should consider replacement.
    cornelius

  • Display dropdown by key data with sorting

    Hi,
    My requirement is to display dropdown by key data with sorting getting this data from XML in KM.
    Tell me different possibilities to sort the data.
    Regards,
    surya.

    Hi,
    Use DropDownByIndex instead of DropDownByKey
    Create a node with a attribute for eg. Colors node with Color attribute and add the values in the elements of the node, Bind attribute to DropDownByIndex UI.
    Create a custom comparator class like below
    import java.util.Comparator;
    import com.sap.tc.webdynpro.progmodel.api.IWDNodeElement;
    import com.sap.tc.webdynpro.progmodel.repository.enums.WDComponentLifecycleEnumInfo;
    public class CustomComparator implements Comparator {
         String attribute;
         public CustomComparator(String attrib) {
              this.attribute = attrib;
         public int compare(Object o1, Object o2) {
              try
                   IWDNodeElement units1 = (IWDNodeElement) o1;
                   IWDNodeElement units2 = (IWDNodeElement) o2;
                   return units1.getAttributeAsText(attribute).compareTo(units2.getAttributeAsText(attribute));
              catch (Exception e)
                   e.printStackTrace();
              //arbitrary order
              return 1;
    Once you read values in the Colors node, call the sortElements method of the node as below to sort the elements of the node
    wdContext.nodeColors().sortElements(new CustomComparator("Color"));
    Regards,
    Amol

  • Replication for Data on DEV and QA - bad idea - primary key problem now

    I goofed.  I tried to use replication to keep the data on my dev machine up to date with the live server.  Now when I try to work on the database, adding new stuff, it fails.  It says there is a primary key problem every time I try to add
    a new item to a table with my program.  I should have realized this would happen!  Now, even though I've removed the replication, I'm having the problem.  Can anyone help me get my database functional again :/  Or should I resort to a database
    restore.  Thanks!

    So you have an IDENTITY column in your table? Run a
    DBCC CHECKIDENT (Transact-SQL) command with option RESEED to fix the current identity value to see if it works then.
    Olaf Helper
    [ Blog] [ Xing] [ MVP]

  • Escape key problems.

    My escape key has been freaking out on me lately. It seems to randomly decide to press itself down very rapidly, and it continues to do so until I press the key myself, fairly hard. The key isn't jammed or anything. Is there anything I can do to fix this, short of paying a rediculous price to get a new keyboard. This escape key problem makes even the most simple action a chore.
    By the way, I'm using a Lenovo 3000 n100.
    Message Edited by PSOCecil on 05-23-2008 06:12 PM

    Yes, they told me they didn't do any laptop work. And I sent it in when it was still under warenty, asking them to look at both my non-working USB drives (that were causing a odd power problem and causin the computer to not start), and my weird escape key. They seemed to of forgotten the escape key, and just looked at the USB drives. It's not under warenty any more, and I don't want to send it back to them again, after the ordeal I had to go through last time.

  • 7373 key problems

    Hi - my 3-month old 7373 has suddenly developed key problems - for example, the "back" key doesn't work at all, and the * key brings up the volume control! This started without me doing anything unpleasant to the phone - any suggestions?
    -Caro

    It's developed a hardware fault.
    You need to visit a nokia care point to get it fixed under warranty.
    Care points:
    UK
    http://www.nokia.co.uk/A4228006
    Europe:
    http://europe.nokia.com/A4388379
    Elsewhere:
    http://www.nokia.com and select your country.

  • IDES Acces Key Problem

    Hi guys
    i install demo version of SAP, but when i try to create a custom Z program in SE38 i got an ACCESS KEY problem, although i tried installation key "29671482393151224771", but its not working
    yes my installation NUMBER = INSTAL
    and other transcation is working like PA30
    is there any body how can help me out, suggestion....?

    If you have the priviledge, you can get the developer key from SAP Marketplace. Else you have to get the developer key from your Basis guy. He/She will get it from SAP Marketplace.
    In SAP Marketplace, go to Keys & Requests -> SSCR Keys

  • Buttons and enter key problem

    hello,
    there are a few projects of enterprise quality which I am developing in java swing. I found out through research that many or rather most people involved with java believe that swing is ready for enterprise class robust desktop applications.
    so I as the team leador am starting my new projects in java swing.
    I personally find that the amount of java libraries present provide a rich set of functionality and it gives big mussle power to the developers.
    I am only concerned about one problem which many of you might have solved.
    I find that I have to hit the space bar instead of enter key to fire an action. in languages like vb I can press enter key to fire the click events. specially in menu items I certainly don't expect my clients to press the spacebar. besides there are many people who are so used to the keyboard and enter key in particular that it will be hard or rather next to impossible to change their habbits.
    how can I make the menu items work with the enter key. I mean do I need to create the code for keypress events every time I also create an action performed method? or is there a way where I can do it without extra coding.
    it is just that I don't want to right extra code for enter key along with click events.
    one more important note.
    I am a blind person and I use the access bridge technology of java.
    so when I am involved in coding, I use the same.
    so may be my problem isn't a problem in the first place.
    kindly provide me some help
    thanks
    Krishnakant.

    The enter-key works on menu-items in all my applications. It did so since I started with java few years ago.
    Maybe some other problem (OS-specific) ?

  • [SOLVED] Function Keys Problem On Dell Inspiron N5010

    Yesterday I bought a new laptop (Dell Inspiron N5010) and immediately installed Arch Linux on it. But when I launched the installation framework, I needed to use fdisk to partition my drive manually and to open another tty, ctrl + alt + f2 or up to f7, none of them worked. When I use f4 or f5 for example, it changes the brightness of the screen cause these keys have icons on them which represent the brightness control. So I quitted, took care of that fdisk issue and got back, installed Arch Linux successfully. When launched in GNOME 3, nothing was changed. It still uses f1, f2, ... and so on as "just function keys" without using "Fn" key. It's fine somehow cause my system automatically detected those keys, I can use every single function of my keyboard. But without using Fn key, I can't actually use any fx key for my own use. For example, I can't use Tilda anymore cause when I use only f1, it tries to open monitor control stuff.
    So... any ideas?
    Edit: It seems that this problem is all about Arch Linux. A friend of mine has the same laptop and he has just tried Mint Debian RC and function keys worked properly. So, there's a problem and it seems it's related to Arch Linux (or maybe Xorg version, somehow?).
    Last edited by Jeaquares (2011-05-18 13:07:06)

    xdunlapx wrote:The function key on my dell laptop was set to the F keys, meaning you have to hit the function key and then an F key to activate the F key. I switched it in the bios so I don't have to hit the function key to activate the F keys. So I would have had to hit Fn+Ctrl-Alt-F1 for example to get to TTY 1. Now since i switched it off in the bios All I have to do is hit Ctrl-Alt-F1 to get to the terminal. But in order to turn off wifi from the F key (for example) I have to hit Fn+F2. It's switched.
    I can't tell you how this was helpful. I've never noticed that there was an option in BIOS's Advanced menu for this. I updated it as "Function Key" and it solved my problem, thanks.

Maybe you are looking for