How to populate the context nodes based on an event

Hi All,
I am having a basic problem. I have created a new Webdynpro Abap application. Here, in the main view, i have define a text view as well as a table. I have created context nodes A and B in component controller. The attributes under A are A1 and the attributes of B are B1,B2, and B3. I have also created an action button C in the same view. These have been mapped to the context nodes in the main view. A1 is mapped to the text view and B1, B2 and B3 are mapped to the table.
My requirement is as follows. When user Clicks on execute, i want to use the value A1 from the text view in a function module and return the values to B1, B2 and B3. B1, B2 and B3 are multiple values mind you.
I have successfully executed the function module within the WDONACTIONC method. How to i accomplish this Basic Task. Please Help
Best Regards
Mazin

Hi Mazin,
Step 3 is as follows...
Say you have a context node, you have to bind this node with table UI element, now this node must contain some context attribute which you have to bind with your columns of table. now say name of context node is cn_table. now what you have to do is get data from FM in the internal table..........
now move data by using move corresponding or by looping depending on requirement to an internal table which has fields with the same name as that of name of your attributes... this is imp to display the data...... now you can bind this internal table with context node using code below.......
data lo_nd_cn_table type ref to if_wd_context_node.
  data lo_el_cn_table type ref to if_wd_context_element.
  data ls_cn_table type wd_this->element_cn_table.
  data it_table type wd_this->elements_cn_table.
  data wa_table type wd_this->element_cn_table.
  data it type standard table of t005t.
  data wa type t005t.
**   navigate from <CONTEXT> to <CN_TABLE> via lead selection
select * from t005t into TABLE it.
  loop at it into wa.
    wa_table-ca_one = wa-land1.
    wa_table-ca_two = wa-landx.
    wa_table-ca_three = wa-natio.
    wa_table-ca_enable = abap_true.
   append wa_table to it_table.
    endloop.
lo_nd_cn_table = wd_context->get_child_node( name =
wd_this->wdctx_cn_table ).
*   get element via lead selection
    lo_el_cn_table = lo_nd_cn_table->get_element(  ).
lo_nd_cn_table->bind_table( it_table ).
ca-one, ca_two, ca_three and ca_enable are name of my context attribute......
regards
Pranav
Edited by: Pranav Nagpal on Dec 22, 2008 10:08 AM

Similar Messages

  • Web Dynpro & Adobe Interactive Forms - how to update the context node

    Hi Experts,
    I got a WD Component with some context nodes that are mapped to some views and are filled in this views. These context nodes are the dataSource for the Interactive Forms. These forms are embedded in a view by UIElement Interactive Forms.
    My problem is, everytime when I change the structure of the context nodes (i.e. there's an additional attribute necessary), I have to design new forms to get the context nodes linked to the form. My existing forms cannot handle updated context nodes.
    The change in the context node is displayed on web dynpro side, in the dataSource view in UIElement property. But in TA sfp there is the old context node structure displayed without any change (i.e. in number of attributes).
    My forms' layout type is ZCI Layout the interface is based on XML.
    How can I easily update the forms' context node structure without creating new forms every time?
    Thanks in advance,
    Tan

    ok, got it.
    by double clicking on templateSource in UIElement properties the interface can be updated.
    Regards from Murphy's Law.
    Tan

  • How to delete the context node in BSP Component?

    Hi,
    I have created a custom context node in one of the components : BP_BPBT.
    Now, I want to delete the context node..
    Could you please tel me, how can I do that?
    Thanks,
    Sandeep

    Hi Sandeep,
      Please check the below link.
    [How to delete Context Node;
    Regards,
    Lakshmi.Y

  • How to read the context node of used component?

    Hi,
    I have component called : SRQM_INCIDENT_H. This component has used component - BTSTATUS.
    Now, I need to read the context node of the BTSTATUS/UserStatus in GET Methods of Context node in SRQM_INCIDENT_H.
    Can you plese help me out.
    Thanks,
    Sandeep

    The component usages can be accessed from the component controller
    You should however assure that the context node is present in comp controlelr of the used component.View context nodes cannot be accessed.
    if not ,then you need to goto the component BTSTATUS ,add the context node  explicitly to comp controller,and do correct bindings to the view context node.
    Once you add the context node to the com controller,yo also need to expose it.
    go to runtime repository->component_interface->interface_controller->context->right click and select ADD CONTEXT NODE, and add you newly creatde context ndoe of comp contorller here.
    Now you cann access it using the code below in your comp SRQM_INCIDENT_H
    data:lr_comp_controller type ref to <ur comp controller class>lr_comp_controller ?= me->comp_controller.
        lr_comp_usage ?= lr_comp_controller->get_component_usage( iv_usage_name = '<name of the comp usage as in runtime repository' ).
        CHECK lr_comp_usage IS NOT INITIAL.
        lr_cnode ?= lr_comp_usage->get_context_node( iv_cnode_name = '<the required context node name>' ).
    Suvidha

  • How to populate a context node on the basis of the values in another node?

    Hi,
    I have a Webdynpro application which has to run on Portal as well as BlackBerry.
    In this application I have a scenario where I need to have a sub node inside a node but as Blackberry doesn't support sub nodes with Singleton value false, I have to use another node for storing the values which earlier wre present in the sub node.
    The actual scenario here is that we have two tables A & B. For each row of table A we have a no of rows in table B. This can be easily accomplished for Web Browser but we need to do this for Blackberry.
    My question here is that how can i populate the data in table B at runtime using the concept of onLeadSelect. I am not able to fully undersans this concept.
    According to my approach I have two a while loop which generates data for  table A and inside this while loop I have another while which generates data for table B corresponding to each iteration of the outer while loop. I create the node elements for the rows of the table B and store them in a list and then store this list in a HashMap corresponding to a key formed by combining the values of all the elements of the row of table A.
    Now I am not able to understand how can I display this data into table on user slecting a particular row.
    Please guide ASAP.
    It wille quite useful if you can provide me with some code snippets for the same.
    Thanks in advance!
    Manish

    Hi Manish,
             In WebDynpro u can use the onLeadSelect event of table A and do all the processing in that method.Like u can use this method to fill ur context node,which will be the source node for table B. So this way u need not to use any hash map.Fill the source node of table B with data corresponding to ur selected data of table A.
      I hope this solution wud help u in solving ur problem.
    Reena

  • How to populate the next screen based on the previous screen table control

    Hi Experts,
            Is this possible to generate the next screen values based on the table control values in previous screen.
    My Requirement is
    In my First screen i m having 5-7 regional offices in table control and also amount field for each regional offices.(amount field is editable)
    User has to enter amount field for Regional office..based on the amount field i need to process the next screen. For Ex if user is entering  amount for 3 regional offices out of 7 regional offices then i need to get the screen for the 3 regional offices..
    Pls suggest me how to do this..
    Regards,
    Zakir

    Hi Zakir,
    Do you have any button for calling the second screen after entering amount in the first table control screen or you have to call the screen on pressing enter on the table control?
    You will have to handle it in the PAI of the table control loop.Get data entered in the table control in your internal table of table control.You can prepare the data passed to the next screen from this internal table. Fill the second screen elements and Use CALL SCREEN XXX. XXX is your second screen no.
    Thanks,
    Pawan

  • How to check the "check box" based on an event on form

    Hi,
    I have couple of text items and a check-box on a form. Is there a way I can check the box automatically when the text item values are edited/enterd by user ?
    I'm using the JS shown below but it doesn't work.
    I have this JS in page header.
    +<script type="text/javascript">+
    +function checkTheBox() {+
    document.getElementById('MY_KBOXNAME').checked='checked';
    +}+
    +</script>+
    And I have this in my form element options.
    onChange=checkTheBox();
    What am I doing wrong?
    Thanks in advance,
    Asha

    Hi,
    For checkbox with name P1_CHECKBOX , first checkbox is refferred using P1_CHECKBOX_0 , second one using P1_CHECKBOX_1 and so on..
    Change document.getElementById('MY_KBOXNAME').checked='checked' . instead of MY_KBOXNAME , use MY_KBOXNAME_0, MY_KBOXNAME_1 ETC depending which checkbox you want to check.
    Regards,
    SK

  • How to read the details in the context node of the custom controller

    Hi friends,
        My requirement is i enhanced the component ICCMP_BP_DETAILS , now on EH_ONSAVE i want to read the details of the Context node in the Custom COntroller .
    In custom controller from ICCMP_BP_DETAIL/CuCoBPDuplicate  From this in context node CUSTOMER is there in that attributes first name last name is there i want to read those details
    so can u pls provide the logic for this how can i get the values.
      am very new to the BSP programming
    Regards
    Yogesh

    Hi Suchitha,
    when i am following the above code the lr_entity is not Bound, so can u pls suggest is there any thing is missing
    i used the below mention code but lr_entity is not bound
    DATA: lr_cuco type ref to CL_ICCMP_BP_CUCOBPDUPLICA_IMPL.
                lr_entity type ref to cl_crm_bol_entity.
    lr_cuco ?= me->get_custom_controller( 'ICCMP_BP_DETAIL/CuCoBPDuplicate') .
    CHECK lr_cuco IS BOUND.
    lr_entity ?= lr_cuco->typed_context->customer->collection_wrapper->get_current( ) .
    CHECK lr_entity IS BOUND .
    lr_entityIF_BOL_BO_PROPERTY_ACCESSGET_PROPERTY_AS_VALUE( iv_attibute =  'FIRST_NAME' ev_attribute = lv_firstname ) .
    Please correct the code if any thing is missing
    Regards,
    Yogesh

  • How to create a context node for "IBHeader" at the view "BuPaIBaseDetail"?

    hi, experts
    for the requirement, i have to get data from a root BO-IBHeader in the view of "BuPaIBaseDetail".But the view already has IBHeader's child object-"IBComponent", whose controller class is "CL_CRM_IC_BUPACONTROLLER_CN08", how can i create the context node for "IBHeader"?
    angerly wait for the answer. thanks a lot

    If you right click on an empty container or a container with an object in it, it has the same available choices to select. However, if you create a blank property node on the block diagram, and wire up the .net object to it, you will see a much different list of properties.
    So, the property node created from right clicking a .NET container will be for that container, even if there is an object inside. To create a property node for the object, you must wire the .NET object to an empty property node on the block diagram.
    Chris Van Horn
    Applications Engineer

  • How to populate the dropdown key values as shown in the below screen shot

    Hi
    i am trying to populate the drop down by key value for trader , for Trader we  have few values i need to populate the Those values in values columns . as shown in the below screen shot .

    Hi,
    Follow below steps
    Step 1 - Create basic wdp table
    Step 2 - Create context to store dropdown values Within your web dynpro application table
    Now you need to create a context node to store the dropdown values, but this needs to be within the context node of your table.
    For this example I will use fields CARRID and CARRNAME from structure SCARR to create the dropdown list within the table context.
    Choose the attributes to represent the id and the text values
    The finished context should now look like this
    Step 3 - Update context mapping within VIEW
    Within the Context tab of your view update the context node you have just modified (CARRIERS) right click and select 'Update Mapping'. Alternatively if this is a new context drag it from the right hand window and drop it onto the context node in the left window,
    Step 4 - Update table field
    Within the layout tab of the view, field the table field you want to replace with with a dropdown and remove the UI element associated with it
    Now insert new dropdownbyindex UI cell element
    Step 5 - Assign Dropdown Ui element to Context
    Click on your UI element within the Layout tab, you will now see all the properties for this element which can be changed. You now need to assign the field within the context which you want to be displayed in the drop down i.e. it will be the CARRNAME field within context element DROPDOWN_CARR. To do this simply click on the button at the end of the 'texts' property (the one with a yellow square and circle on it) and select the correct context field.
    Step 6 - ABAP code to populate dropdown list and set correct initial value
    Insert the following ABAP code into the appropriate place. For this example it will go within the WDDOMODIFYVIEW method of the view.
      Data: it_scarr type standard table of scarr, wa_scarr like line of it_scarr, context_node type ref to if_wd_context_node.  Data: it_ddcarr type STANDARD TABLE OF if_main=>element_DROPDOWN_CARR, wa_ddcarr like line of it_ddcarr, lr_element TYPE REF TO if_wd_context_element, ld_tabix type sy-tabix, ld_index type sy-index, it_carriers type STANDARD TABLE OF if_main=>element_CARRIERS, wa_carriers like line of it_ddcarr.  select * from scarr into table it_scarr. sort it_scarr by carrid.  * select * from scarr into table it_scarr. context_node = wd_context->get_child_node( name = 'CARRIERS' ).  * Get all rows of table and values stored in each cell currently displayed to user context_node->get_static_attributes_table( importing table = it_carriers ).  if sy-subrc eq 0. loop at it_carriers into wa_carriers. free lr_element. ld_tabix = ld_tabix + 1.  *     assign context_node to table context context_node = wd_context->get_child_node( name = 'CARRIERS').  *     assign lr_element to row of table lr_element = context_node->get_element( ld_tabix ).  *     assign data to dropdown of the row  context_node = lr_element->get_child_node( name = 'DROPDOWN_CARR'). context_node->BIND_TABLE( it_scarr ).  *     Set correct initial value read table it_scarr into wa_scarr with key carrid = wa_carriers-carrid. ld_index = sy-tabix. context_node->set_lead_selection_index( index = ld_index ).  endloop. endif.
    Step 6 - Save, Activate and Run
    Save and activate your abap web dynpro, now when you execute it you should see a drop down object similar to the following:

  • How to populate the Language Key description is not available

    Hi,
    Question: How to populate the Language Key description is not available in the Customer text table
    The problem is ;
    Customer no : 0012345
    For this Customer no description is maintained only in EN, JA ,FR from R3 side.
    EN : HP International Ltd
    JP:HP &#12398;&#22269;&#38555;&#30340;&#12394;&#26666;&#24335;&#20250;&#31038;
    FR: Ltd International de HP
    There is no value for Language ES.
    BW side:
    User is login into language Key ES and executing the report based on this Customer no. There is no Customer text value maintained in language Key ES. It should populate the text value empty. BW system - Language ES is installed.
    I have a Reporting requirement is - I need to populate the text value for this customer No: HP International Ltd when the user login to language Key ES and execute his reports.
    /BI0/TCUSTOMER – Customer text table – I am able to see the description for the EN, JP, FR text values.
    EN: HP International Ltd
    JP: HP &#12398;&#22269;&#38555;&#30340;&#12394;&#26666;&#24335;&#20250;&#31038;
    FR: Ltd International de HP
    If the Customer text is not available in the text table of customer for language key ES - I have to populate the any one of the existing customer text values into the language key ES - example
    0012345 ES  HP International Ltd
    Simplest solution if we maintained ES customer description in R/3 should be ok.
    Is their any other logic which I can implement in BW.

    Hi,
    If you are opting to load Customer Text, there are two options:
    1. R/3 maintained.
    2. Generic Extraction using Flat Files.
    Hope it helps..
    Regards,
    GPK.

  • Value not available in the context node

    Hi,
    I have created one custom component through BSP_WD_CMPWB  with only one view called u2018partneru2019 with sample button.
    In this view partner ,then  created one  model context node with reference to  u2018 BuilHeaderSearchu2019 search component with only one attribute  u201CPartner IDu201D.
    When I test the component , WebUI  screen shows partner id input box, and sample button. After  entering partner id value in the input box, then I am pressing sample button. But entered value not  available in the context node.  Please help me, how can i get this value?
    Kathir.

    Hi,
    Check the set_method of that attribute and compare with standard.
    Regards,
    Shobhit

  • How to enhance the context menu in Web Applications - BW 7.0

    We have to enhance the context menu of several Web Applications and,
    initially, we based our solution on the paper "How to enhance the
    context menu of Web Applications", from June, 2002, but the solution
    described on the paper refers to the BW version 3.0 and we need the
    solution for the BW version 7.0. The technical content described on the
    paper, version 3.0, is very different from the content of the version
    7.0, used by us. Is this feature available for the version 7.0?

    Hi,
    did you find a solution already?
    Thanks,
    Frank

  • How to populate the time component of a cube?

    We have a question regarding how to populate the time component of a cube. Let me explain:
    We are using OWB 10gR2. We have created a cube with several dimensions. We are now building the mapping to load the cube. The cube operator has two columns for every dimension (e.g., "customer" and "customer_id" for the "customer" dimension).
    We understand that, in this case, "customer_id" stands for the dimension business key, so we create an arrow from the business key in the source table to the "customer_id" column in the cube operator.
    So far so good. The mapping works all right, and the cube is loaded correctly.
    Now we need to do the same for the time dimension. We have already created the time dimension and we have loaded it. We have also included it in the cube, so now we have two new columns in it: "time_day_code" and "time", both NUMBER data type.
    We have the "sale_date" column (DATE data type), in the source system and, of course, now we want to populate the date column in the cube. We suppose that, somehow, we have to translate the "sale_date" field into the numeric column of the surrogate key of the time dimension. How should do we do this? I suppose that OWB must do the translation for us, just as it does for the other dimensions, but how? We have been looking into the manuals, and we have found no explanation on how to go about this.
    Any help would be appreciated.
    Best regards
    Juan Algaba

    Hi Juan
    You are right this should have been in the manuals, checked and there is only a brief mention (Using a Time Dimension in a Cube Mapping section)
    The identifier format should have been documented for each level and will involve creating the formatted attribute for input to the cube operator's time dimension reference attribute.
    The time dimension business keys are stored as follows;
    Day Level - YYYYMMDD
    Month Level - YYYYMM
    Week Level - YYYYWW
    Quarter - YYYYQ
    Year - YYYY
    If you have a source that has a SQL date datatype for example and want to construct the key for a cube's time dimension at the day level something like the following expression can be used to construct the time reference from a SQL date...
    to_number(to_char( time_key, 'YYYYMMDD'))
    The result of this expression can be used as input to the cube's time dimension attribute.
    Cheers
    David

  • In BI how to filter the selection options based on inputs on top field

    Hi Friends,
    In BI, How to filter the selection options based on inputs on top field.
    The system should automatically filter the lower level drop downs based on the selection of a higher level.
    For e.g. :
    If a user selects a Country then the States drop down should only display the State's belongs to the Country. Similarly when a State is selected, the District drop down should display only those District's belongs to the State.
    Thanks in Advance.
    Regards
    Jayaram M

    Hi Anil,
    Thanks for reply but I couldn't use Compounding Characteristic here. Need some other solution.
    Regards
    Jayaram M

Maybe you are looking for

  • BUG:  Video layers black, not displaying

    I've edited now for a week with FCP X v. 10.0 and have just run into a bug and haven't found a workaround for it yet.  I have a project that has apparently gotten corrupted somewhere along the way.  It was working before, but when I tried to export m

  • CTIOS Client: Enabling Chat & Agent Stats

    Working with CTIOS client in a lab (8.5).  Have one agent and one supervisor (spv configured as spv of agent on team).  Two issues: 1)  Chat:       a) I AM able to send chat from the agent to the spv.  However, the window does not automatically pop u

  • Problem with iphone 5 in recovery mode

    hi try to update my phone. and now it stuck in there can not do anything with the phone

  • Thinking of upgrading to an iMac

    Hi - I currently have a 10 year old eMac Power PC G4 running OS X 10.3.9, which I'm very fond of and has never let me down, but I am thinking of upgrading to a new iMac running OS X Snow Leopard. My worry is that I have a lot of software on my exixti

  • Effects panel in premier pro cc is their a way to retrieve it ?:D

    see question above