Configuring Dynamic drop down in ABAP Function Module based VC application

Dear Expert,
Can someone help me in configuring Dynamic Drop down list in ABAP function module based
VC application, so that all the backend data like material description list should display in drop down list followed by * search.
Thanks & Regards,
Kundan

Hi Anja,
As you suggested i design a combo box with dynamic entry list. But it not displaying any item for selection. Combo box is showing empty. Can you please help me in this so all the backend list should display in combo box dynamically?
Thanks,
Kundan

Similar Messages

  • Debugging of ABAP Function Module through ISA Application CRM B2C 4.0

    Hi Experts
    There is way to Debug ABAP FM through ISA CRM b2c Application by Modifying some XML Files as per Extn Guide.
    I tried modifying the <APPLICATION_HOME>\WEB-INF\xcm\customer\modification\modification-config.xml After that I restarted the Application .
    But it is not Breaking for Both Statefull & Stateless FM after running my Application.
    With Some Help i found that if we try it on Remote System ( Means SAP GUI has to in Same System where CRM is Installed ???????????). but that is not Advisable Right !!!.
    So if i am able to Debug ABAP Function Module through ISA Application from any Other remote System.
    I think it will be very Useful.
    Thanks & Regards
    Ravi Sah

    Ravi
    It is other way around !!!
    You should have SAP GUI installed on the machine in which you start(access) your B2C Application. This enables for ABAP Debugging.
    We have tried this and works fine for us !!!
    Thanks
    Jack
    <b>Allot points if my post helps !!!</b>

  • Filling dynamic drop down in adobe interactive form( webdynpro ABAP)

    HI all,
    Im new in Webdynpro ABAP, my requirement is to fill drop down list in adobe interactive form. i created adobe form and its working fine.
    I Created context like ROOT(cardinality 1:1)->DATANODE cardinality 0:n. This context is for drop down and in wddoinit i did  like this.
      IN WDDOINIT ,
    DATA lo_nd_root TYPE REF TO if_wd_context_node.
      DATA lo_nd_datanode TYPE REF TO if_wd_context_node.
      DATA lo_el_datanode TYPE REF TO if_wd_context_element.
      DATA ls_datanode TYPE wd_this->elements_datanode.
    navigate from <CONTEXT> to <ROOT> via lead selection
      lo_nd_root = wd_context->get_child_node( name = wd_this->wdctx_root ).
    navigate from <ROOT> to <DATANODE> via lead selection
      lo_nd_datanode = lo_nd_root->get_child_node( name = wd_this->wdctx_datanode ).
    get element via lead selection
      lo_el_datanode = lo_nd_datanode->get_element(  ).
    ls_datanode[] = lt_dna_value[].
    CALL METHOD lo_nd_datanode->bind_table
      EXPORTING
        new_items            =  ls_datanode
        set_initial_elements = ABAP_TRUE.
       index                =
    while executing  i'm getting this error ": WebDynpro Exception: ADS: com.adobe.ProcessingException: No output was generated while rendering: Stream for: PDFOut.(200,101). " . can u please tell me how to bind value for drop down.
    I created sample table in same form and i binded same value to table, that time its executing fine.
    can u please tell me solution for this Scenario.
    Thanks
    Hemachandran.
    Edited by: hemachandran R on Sep 12, 2008 2:27 PM

    hi,
    My requirement, is to use dynamic drop down in dynamic table. I am using webdynpro abap.
    i populated the value in drop down.
    Its working fine but the problem is how to fill the default value in drop down. because i want to bind the default value which im getting specify value from the table.because each row
    im getting different values, like first row
    CAR
    , that CAR want to fill as a default value in drop down  and second row  as
    BIKE
    that BIKE  want to fill as default value in drop down  ( example drop down contain   car , bike , cycle).
    In adobe form i binded like this
      $record.DATANODE.DATA[*].DNA_RATING
    i dont know whether this one is correct or wrong  .
    im getting default value as empty.
    please give me some solution how to do this.its very urgent
    thanks
    hemachandran.

  • Dynamic drop down list in Adobe forms

    I have created a drop down list using enumerated drop down list from webdynpro native tab and binded in the object palette by giving $record.sap-vhlist.DESCR\.DATA\.FIELD.item[]* in the list items dynamically.DESCR is the field in the internal table into which i fetched data from the database table .I have written this code in a BADI.I dont know whether my form's display type is activex or native? I am not getting any values in the drop down list.can anybody please tell me what might be missing and how should i know whether my form is ActiveX or Native?
    My form is called from portal so i have used BADI to connect portal to form

    Hi sarang,
    I have done a dynamic drop down list in which DESCR field comes from database table and pops into the drop down dynamically. I was working for a PCR scenario so the adobe form was called from portal.I will tell u all the required steps.It might work for u as it is working for me:
    1.In the form:
    I used two elements from library first is a "ENUMERATED DROP DOWN LIST NO SELECT" from web-dynpro native tab and second is "ISR_TEXT DISPLAY INVISIBLE ON EDIT MODE" from ISR controls tab.Place them one on other inthe form.
    For drop down list the setting are:
         In object, field tab click on list items there in ITEMS put :$record.sap-vhlist.DESCR\.DATA\.FIELD.item[*].in ITEMS TEXT write text in ITEMS KEY write key.
         In binding,in default binding put $record.DESCR.DATA[*].FIELD.
    For text element the settings are:
         In binding,default binding put Normal.
         when we select ISR_TEXT DISPLAY INVISIBLE ON EDIT MODE it automatically comes with calculated read only int he value tab.so open script editor and place the below code:
    $record.DESCR.DATA.FIELD (in calculate).
    2.Now the code in BADI is as follows:
    In BADI we have to write the code for drop down list in the METHOD "SCENARIO_SET_ADDITIONAL_VALUES"
    As i didnt change the standard BADI i added an enhancement spot in which i wrote a function module which fills ADDITIONAL_DATA. and the below code fills the ADDITIONAL_DATA .
    DATA: t_t572b TYPE STANDARD TABLE OF t572b WITH HEADER LINE,
            t_t554t TYPE STANDARD TABLE OF t554t WITH HEADER LINE.
      SELECT * FROM t572b INTO TABLE t_t572b WHERE sprsl EQ 'E'.
      CLEAR ls_additional_data-fieldindex.
      LOOP AT t_t572b.
        ADD 1 TO ls_additional_data-fieldindex.
        ls_additional_data-fieldname ='DESCR_KEY'.
        ls_additional_data-fieldvalue = t_t572b-descd.
        APPEND ls_additional_data TO additional_data.
        ls_additional_data-fieldname ='DESCR_LABEL'.
        ls_additional_data-fieldvalue = t_t572b-descr.
        APPEND ls_additional_data TO additional_data.
        CLEAR t_t572b.
      ENDLOOP.
    For DESCR field the we have to declare  DESCR_KEY and DESCR_LABEL in the place holders for key values and palce holders for default values in characteristics tab(where all the fields for the form are defined) of ur respective scenario.(where ur pcr scenario is defined)
    Hope ur problem got resolved.
    Please let me know if any doubts.
    If ur form is not called from portal and u want a dynamic drop down list the difference is put a data drop down list and in object, field tab click on list items there in ITEMS select the field into which u populated the data from the database table (this code shud be written in code Initialization in the respective interface) and in ITEMS TEXT put $ in ITEMS KEY put $.and in binding as we normally do bind it to the respective field in which the data is populated from database table.
    It should work.

  • Call ABAP function module from script?

    Hi,
    I have an ABAP function module, which works fine when I call it in a transformation.
    Since I don't need to execute this function for each record but rather for each file I process, I would like to move the call from the DataFlow to a script in the WorkFlow. When I click on the 'functions' button the ABAP FM is available in my SAP Datastore, so I drag and drop it into my script. I also make sure to populate all required variables.
    There are no error messages or warning when I check my job definition.
    When I execute it, I get the following RFC error:
    Function call <xxx  ( abcd ) > failed, due to error <150413>: <RFC CallReceive exception <FUNCTION_NOT_FOUND>.>.
    Is it just not possible to call an RFC enabled function module in SAP from a script or am I doing something wrong here?
    Thanks,
    Jan.

    Could you please let me know how I can call an abap function module from a transformation? (from abap xslt program). I know how we can call methods of a class from the transformations, but no idea how we can call function modules. Any suggestions or a sample code snippet towards this will be very useful for me.
    Thanks,
    Shashi.

  • Call an ABAP Function module on click of Button in BSP page

    Hello ,
    i would like to run a ABAP function module on click of a button in BSP page.
    or in other words i want a Funtion module ex: 'test1' to run after clicking this button ex: 'button1'
    and how to pass the values for a function module after clicking the button.
    i an new to bsp application .
    Can anyone help me on this .

    Hi Shalaxy,
    Triggering a URL to WDJ:
    I suppose the URL of WDJ app. is also a portal URL. I assume that from a BSP application inside portal you need to trigger the WDJ url.
    But the catch is that you cannot hotcode this URL, since it varies for a development, quality and production systems(diff. portal environments).
    To solve this issue, ABAP provides a system variable named sy-sysid, which says want system your ABAP system is, normally a development R/3 system will be associated to development portal system and quality R/3 to quality portal ans so forth.
    So you could have a internal table/db table/ variable for dev, quality or prod portal urls and from the bsp on button click based on the value in the sy-sysid you can trigger the url accordingly.
    Creating a URL in WDJ
    The above is about triggering a WDJ from BSP. But if you dynamically want to create a link in WDJ on a button click, then apparently you could not do that from BSP, since the applications are different. All you could do is to pass some URL parameters to WDJ application from BSP app. Then based on the URL parameters the WDJ application has to dynamically create a link and add it to its application.
    Hope it helps.
    Regards,
    Maheswaran
    Edited by: Maheswaran B on Mar 1, 2010 4:17 PM

  • Web Dynpro Java Internationalization and backend ABAP function modules

    Friends,
    I have a requirement where I want my Web Dynpro Java application to support BRAZIL and CHINESE.
    I have been through the sample programs and tutorials and I understand how to support my application in these 2 languages. The challenge I am facing is how to communicate the language to the backend code (ABAP function modules) so that the function modules can written language specific error messages and texts.
    I searched SDN but could not find anything. Your help is appreciated.

    Prashant,
    When you are configuring JCo connection in WebDynpro Content Administrator, just left language settings blank for metadata connection (you may do the same for data connection). Now WD will supply language of currently logged-in user when obtaining connection settings from system landscape and you'll get necessary functionality.
    By default locale of user determined by parameter sap-locale (sap-locale=de_DE for example), settings of user's browser and lastly preferences of user stored in UME.
    Btw, BRAZIL (or Portugees for this matter) is not fully supported language by SAP, so R/3 side may be not  translated or partly translated.
    Valery Silaev
    SaM Solutions
    http://www.sam-solutions.net

  • --urgent Can I use table data to create a dynamic drop down menu?

    Hi,
    I am asked to investigate the possibility of using APEX to create a table driven dynamic drop down menu? The deadline is tomorrow but I have spent quite a bit of time but still have not any clue. Can any one have such experience to point me a way to focus on?
    Many thanks.
    Jennifer

    Thanks you very much for the help Kevin.
    Currently my company is using htp.p style to create web app and using the dynamic menu in a similar way as you explained. Now they want to move to Apex and still keep dynamic menu functionality. After reading your response and research I have done I think I can embed it into Apex application by creating the similar table and PL/SQL package and let Apex to call the PL/SQL package when the application is first called. However may I ask you a question about how to call such pl/sql procedure in Apex? .
    The current application has the following URL, from which the procedure pkg_main.print_menu is called and html home page with dynamic menu is displayed.
    Http://app server:1234/pls/applicationname/pkg_main.print_menu?p_new_window=N
    BUT what about the Apex? The Apex URL format is like the following, where 11563 and 1 is application id and page number. Assume that 1 is home page, but HOW the procedure is called, from WHERE?
    http://apex.oracle.com/pls/apex/f?p=11563:1:3397731373043366363
    Jennifer

  • How do I enable multiple dynamic drop down boxes?

    I'm using Windows 2000, Java SDK 2 Standard, Tomcat, Apache, Microsoft Access and Macromedia Dreamweaver Ultradev 4.
    With UltraDev I'm trying to create a jsp page that has more than one dynamic drop down box or more than one dynamic select list box. I can show one dynamic object and as many static objects as I need. But when I add a second dynamic drop down box, with a second recordset, the page will only display the first dynamic object and all content following that object will not display.

    Here's the code:
    <%@page contentType="text/html; charset=iso-8859-1" language="java" import="java.sql.*"%>
    <%@ include file="Connections/conn.jsp" %>
    <%
    Driver DriverRecordset1 = (Driver)Class.forName(MM_conn_DRIVER).newInstance();
    Connection ConnRecordset1 = DriverManager.getConnection(MM_conn_STRING,MM_conn_USERNAME,MM_conn_PASSWORD);
    PreparedStatement StatementRecordset1 = ConnRecordset1.prepareStatement("SELECT STATE_NAME, COUNTRY FROM STATE");
    ResultSet Recordset1 = StatementRecordset1.executeQuery();
    boolean Recordset1_isEmpty = !Recordset1.next();
    boolean Recordset1_hasData = !Recordset1_isEmpty;
    Object Recordset1_data;
    int Recordset1_numRows = 0;
    %>
    <%
    Driver DriverRecordset2 = (Driver)Class.forName(MM_conn_DRIVER).newInstance();
    Connection ConnRecordset2 = DriverManager.getConnection(MM_conn_STRING,MM_conn_USERNAME,MM_conn_PASSWORD);
    PreparedStatement StatementRecordset2 = ConnRecordset2.prepareStatement("SELECT FIRSTNAME, LASTNAME, AGE FROM PLAYER");
    ResultSet Recordset2 = StatementRecordset2.executeQuery();
    boolean Recordset2_isEmpty = !Recordset2.next();
    boolean Recordset2_hasData = !Recordset2_isEmpty;
    Object Recordset2_data;
    int Recordset2_numRows = 0;
    %>
    <html>
    <head>
    <title>Untitled Document</title>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
    </head>
    <body bgcolor="#FFFFFF" text="#000000">
    <form name="form1" method="post" action="">
    <p>
    <select name="select2">
    <option value="Canada">Canada</font></option>
    <option value="France">France</font></option>
    <option value="French Guiana">French Guiana</font></option>
    <option value="French Polynesia">French Polynesia</font></option>
    <option value="French Southern Territories">French Southern Territories</font></option>
    <option value="Germany">Germany</font></option>
    <option value="United Kingdom">United Kingdom</font></option>
    <option value="United States">United States</font></option>
    </select>
    </p>
    <p>
    <select name="select">
    <%
    while (Recordset1_hasData) {
    %>
    <option value="<%=(((Recordset1_data = Recordset1.getObject("COUNTRY"))==null || Recordset1.wasNull())?"":Recordset1_data)%>" ><%=(((Recordset1_data =
    Recordset1.getObject("STATE_NAME"))==null || Recordset1.wasNull())?"":Recordset1_data)%></option>
    <%
    Recordset1_hasData = Recordset1.next();
    Recordset1.close();
    Recordset1 = StatementRecordset1.executeQuery();
    Recordset1_hasData = Recordset1.next();
    Recordset1_isEmpty = !Recordset1_hasData;
    %>
    </select>
    </p>
    <p>
    //Here's where things go awry
    <select name="select4">
    <%
    while (Recordset2_hasData) {
    %>
    <option value="<%=(((Recordset2_data = Recordset2.getObject("FIRSTNAME"))==null || Recordset2.wasNull())?"":Recordset2_data)%>" ><%=(((Recordset2_data = Recordset2.getObject("FIRSTNAME"))==null || Recordset2.wasNull())?"":Recordset2_data)%></option>
    <%
    Recordset2_hasData = Recordset2.next();
    Recordset2.close();
    Recordset2 = StatementRecordset2.executeQuery();
    Recordset2_hasData = Recordset2.next();
    Recordset2_isEmpty = !Recordset2_hasData;
    %>
    </select>
    </p>
    <p>
    <select name="select5">
    </select>
    </p>
    <p> </p>
    </form>
    <form name="form2" method="post" action="">
    <select name="select3">
    </select>
    </form>
    <p> </p>
    </body>
    </html>
    <%
    Recordset1.close();
    ConnRecordset1.close();
    %>
    <%
    Recordset2.close();
    ConnRecordset2.close();
    %>

  • Passing an XML file from WebDynpro app to ABAP function module

    Hi all,
    I'm stuck with a problem, and am hoping one of you could let me know how to proceed:
    I need to pass an XML file (or at least the entire content of the XML) from my WebDynpro application to a backend ABAP function module. What I tried was this:
    In my WebDynpro app, I read the XML and convert the content into one long string (using java.io.FileReader and java.io.BufferedReader). In my ABAP function module I created an import parameter of type String. I then imported the ABAP Function module into my WebDynpro app as a model. I then tried to pass the XML string to the ABAP module. What happens is this:
    If the size of the string (XML) happens to be less than 255 characters, then it works. That is, the string is passed to the ABAP function module and I can see the contents. However, if the XML string happens to be greater than 255 characters, then it does not work. The string at the ABAP side is empty. Surprisingly, the ABAP module does not throw an error either. It just displays an empty string.
    Could you please tell me what the problem is?
    Thanks & Regards,
    Biju

    Hi Biju ,
    Welcome to SDN.
    If the import parameter is defined as type string it should work, however did you check whether your application pass it properly?
    I have applications using strings as import parameters working fine. (webapplications (BSP) to RFC)
    Regards
    Raja

  • Issue in creating web service for a ABAP Function Module

    Hi,
    now i'm learning how to create web service for a ABAP Function Module. I used the following steps.
    1. select the Function Module, named "zws_test".
    2. in the context menu, select "create->proxy object". so we enter into wizard.
    3. in the wizard, press the radio button "Service Provider".
    4. in the next page, press the radio button "Existing ABAP Objects(Inside Out)".
    5. In the next page, Enter the "zws_test_prvider" as Service Definition and select "Function Module" as Endpoint Type.
    6. in the next page, enter "zws_test" as Function Module and mark the "Mapping der Namen" button
    7. in the next page,select "PRF_DT_IF_SEC_LOW" as Profile and mark "Deploy Service".
    8. Save in the local package.
    9. then it will pop up a window with title "WSDL Source". i selected "URL/HTTP Destination" and press "OK".
    10.in the next page, i enter the URL as "http://hostname:portnumber/", and press "OK".
    11. then it will pop up a window with title "Display logs". A record with error message "HTTP error(return code 404, message "Not found")" appears.
    12. i press "ok" and a service provider with name "zws_test_prvider" appears in my local package.
    13. i use "zws_test_prvider"'s URL to create a service consumer "ZCO_WS_TEST_CONSUMER" and logic portal "LP1".
    14. But when i test my service consumer "ZCO_WS_TEST_CONSUMER", it will throw an exception "cx_ai_system_fault" with errortext "SOAP:14 Unexpected element -el=definitions ns=http://schemas.xmlsoap.org/wsdl/".
    15. I use t-code SM59 to test connection  and get the following info.
          Status HTTP Response     200
          Status Text                      OK
          Duration Test Call             328 ms.
    who can give me the reasons about item 11 and 14, and explain me how to create service provider and service consumer for a Function Module.
    Thanks in advance
    Johnney

    have you seen this weblog
    /people/thomas.jung3/blog/2004/11/15/bsp-150-a-developer146s-journal-part-xiii-developing-abap-webservices

  • How to populate data from dynamic drop down list to the text field

    Hi,
    I tried to populate data from dynamic drop down list to city field. I would like to concat data from drop down list.When selecting add button to add the item and select item from drop down list, data should be displayed in the text field. However, Please help. I spent alot of time to make it works I am not successful.
    Please see the link below.
    https://acrobat.com/#d=SCPS0eVi6yz13ENV0cnUdw
    Thanks for your help
    Cindy

    Hi Rosalin,
    Loop the hidden table, get the values and populate drop down in each iteration.
    DropDownList1.addItem("Text","Value");
    You can use one more solution for this scenario. If it is a matter of 2,3 dropdowns, put three dropDowns in the form layout and give seperate static data binding to them. At run time make the dropDowns hide/visible as per the requirement.
    Hope this helps.
    Thanks & Regards,
    Sanoosh

  • Crystal Reports for VS2010 using a custom SAP ABAP function module data source

    I recently worked with Crystal Reports 2011 and was able to connect and retrieve data from our R/3 system via an ABAP function module. While researching other features, I found this version that can be installed into Visual Studio 2010. The parameters are not very user friendly in Crystal Reports so I was hoping to create a custom dialog to collect my report parameters.
    Does anyone know if I were to install Crystal Reports for Visual Studio 2010, would I be able to design a front-end selection screen in a Visual Basic form and then pass the input to through the Crystal Reports connection to my ABAP function module to retrieve the data filtered on the back-end by the selection screen parameters and return the results to be reported in the Crystal Reports output?
    I am using Visual Studio 2010 Professional Visual Basic with the .NET Framework 4.0 on 32-bit Windows 7. I was able to connect to our R/3 system in Crystal Reports 2011, so if I were to install Crystal Reports for VS2010, would there be a similar way of connecting to SAP?
    Any assistance or direction would be greatly appreciated.
    Thanks,
    Bryan

    Hello Bryan
    I don't know for sure, but I doubt this will work in CRVS2010. Only hope is that the utility available for download in this KBA will point you in the right direction.
    - Ludek
    Follow us on Twitter
    Got Enhancement ideas? Try the SAP Idea Place
    Share Your Knowledge in SCN Topic Spaces

  • Help on ABAP Function Module (Unit 1)

    Hello ABAP Experts,
    I need help with the below mentioned lesson plan. I donot have source code for The ABAP Function Module - BC401_GET_SEP_STRING. For the Source Code Solution in the Lesson Plan to work, I need the source code for the above mentioned function module.
    The Lesson Plan with Solution is posted below:
    Exercise 1 
    Unit: Data Types and Data Objects in Detail
    Topic: Defining Data Types and Data Objects
    Basic Statements
    Processing Character Strings
    At the conclusion of these exercises, you will be able to:
    u2022     Define structure types locally in the program
    u2022     Define elementary and complex data objects
    u2022     Split strings
    u2022     Use conversion rules
    u2022     Display the contents of data objects in lists
    In this exercise, you will use a template to create a program that receives a single data record from the database table SFLIGHT in form of a character string. The program will split the this character string into its components and display it formatted in a list.
    Because the focus of this exercise is not on the transfer of data as a character string, we will use a function module that will provide us with the required database. This will simulate actual cases, such as data transfer from an external system.
    Program: ZBC401_##_SPLIT_STRING
    Template: SAPBC401_DTOT_SPLIT_STRING
    Model solution: SAPBC401_DTOS_SPLIT_STRING
    is your two-digit group number
    1-1 Copy the program, SAPBC401_DTOT_SPLIT_STRING and give it the new name ZBC401_##_SPLIT_STRING.
    1-2 Familiarize yourself with the main body of the program. Pay special attention to the content of the data object datastring after the function module call. Use the Debugger to do this, and/or display the character string in a list. (The function module itself is here seen as a black box. For this exercise, it is not necessary to understand its construction.)
    1-3 To be able to split the character string into its components you must first remove the ## characters. Remove the two leading separators from the character string first. Then copy the initial part up to the closing separators to the auxiliary variable set_string. For this, set_string has to be defined appropriately.
    1-4 Now use the separators to split the contents of the auxiliary variable set_string into the structure wa_flight_c. The latter is typed with the local program structure type st_flight_c. You still have to comment out the components of this structure type and assign them an appropriate type.
    1-5 As a test, display the fields of the structure, wa_flight_c in a list.
    1-6 In the list displayed in exercise 1-5, you should have observed that some of the fields were displayed without formatting u2013 for example, the PRICE field. Your next step is to change this.
    To do this, convert the data you have extracted by copying it to data objects with suitable types. Also, not all components of wa_flight_c are to be displayed.
    For this purpose, a structure wa_flight has already been defined. It is typed with the structure type st_flight. You must comment out the components of st_flight and find appropriate types for these components for the formatting. Then copy the identically-named components of the character-type structure wa_flight_c to the fields of the structure wa_flight.
    Display the contents of the structure wa_flight in a list. Use the appropriate formatting options for the WRITE statement for the fldate and price components.
    Data Types and Data Objects in Detail Solution 1
    Unit: Data Types and Data Objects in Detail
    Topic: Defining Data Types and Data Objects
    Basic Statements
    Processing Character Strings
    REPORT sapbc401_dtos_split_string.
    TYPES:
    BEGIN OF st_flight_c,
    mandt(3) TYPE c,
    carrid(3) TYPE c,
    connid(4) TYPE n,
    fldate(8) TYPE n,
    price(20) TYPE c,
    currency(5) TYPE c,
    planetype(10) TYPE c,
    seatsmax(10) TYPE n,
    seatsocc(10) TYPE n,
    paymentsum(22) TYPE c,
    seatsmax_b(10) TYPE n,
    seatsocc_b(10) TYPE n,
    seatsmax_f(10) TYPE n,
    seatsocc_f(10) TYPE n,
    END OF st_flight_c,
    BEGIN OF st_flight,
    carrid(3) TYPE c,
    connid(4) TYPE n,
    fldate TYPE d,
    price(9) TYPE p DECIMALS 2,
    currency(5) TYPE c,
    planetype(10) TYPE c,
    seatsmax TYPE i,
    seatsocc TYPE i,
    END OF st_flight.
    DATA:
    datastring TYPE string,
    set_string TYPE string,
    wa_flight_c TYPE st_flight_c,
    wa_flight TYPE st_flight.
    START-OF-SELECTION.
    CALL FUNCTION 'BC401_GET_SEP_STRING'
    EXPORTING
    IM_NUMBER = '1'
    IM_TABLE_NAME = 'SFLIGHT'
    IM_SEPARATOR = '#'
    IM_UNIQUE = 'X'
    IMPORTING
    ex_string = datastring
    EXCEPTIONS
    no_data = 1
    OTHERS = 2.
    IF sy-subrc <> 0.
    MESSAGE a038(bc401).
    ENDIF.
    SHIFT datastring BY 2 PLACES.
    FIND '##' IN datastring.
    IF sy-subrc <> 0.
    MESSAGE a702(bc401).
    ENDIF.
    SPLIT datastring AT '##' INTO set_string datastring.
    SPLIT set_string AT '#' INTO
    wa_flight_c-mandt
    wa_flight_c-carrid
    wa_flight_c-connid
    wa_flight_c-fldate
    wa_flight_c-price
    wa_flight_c-currency
    wa_flight_c-planetype
    wa_flight_c-seatsmax
    wa_flight_c-seatsocc
    wa_flight_c-paymentsum
    wa_flight_c-seatsmax_b
    wa_flight_c-seatsocc_b
    wa_flight_c-seatsmax_f
    wa_flight_c-seatsocc_f.
    MOVE-CORRESPONDING wa_flight_c TO wa_flight.
    WRITE: /
    wa_flight-carrid,
    wa_flight-connid,
    wa_flight-fldate DD/MM/YYYY,
    wa_flight-price CURRENCY wa_flight-currency,
    wa_flight-currency,
    wa_flight-planetype,
    wa_flight-seatsmax,
    wa_flight-seatsocc.

    this FM is to get one element value from the XML
    if you want to convert the whole XML use FM SMUM_XML_PARSE
    Regards
    Raja
    Kindly close your previous threads and assing points.
    Re: Creation of SIMPLE TRANSFORMATIO(ST)for deserialisation of XML ->ABAP data.

  • Dynamic Drop-down list - selected value can't be cleared ...

    1. check out the following code of a dynamic drop down list using cursor :-
    DECLARE
         -- DROP-DOWN LIST OF ALL DEPARTMENTS
         TEMPNUMBER NUMBER(2) := 2 ;
    -- Because we've to initialize the list
    -- at least with 1 item.
    CURSOR C_DEPT IS
         SELECT DEPT_ID FROM DEPARTMENT;
    BEGIN
         ABORT_QUERY ;
         CLEAR_LIST('DEPTLIST');
         FOR TEMP IN C_DEPT LOOP
         ADD_LIST_ELEMENT( 'DEPTLIST', TEMPNUMBER, TEMP.DEPT_ID, TEMP.DEPT_ID );
         :SRBLOCK.LST := TEMP.DEPTNO;
         -- prev. line set the newly selected value
         TEMPNUMBER := TEMPNUMBER + 1 ;
         END LOOP;     
    END;
    2. problem is as we've to atleast initialize with one list item... that item can't be cleared with CLEAR_LIST.
    3. how can i actually clear that and still use cursor. because i've searched forum for this thing and found all those code not working ... for my project ...
    4. quick help needed ...

    Hi Omar,
    I have solution for you
    To populating or refreshing the lists you can use
    two procedures:
    One of them - generic, which can be used for all types of list
    Another is specific which contain a SQL statement to retrieve the data for
    particular list.
    1. Specific procedure:
    PROCEDURE GET_DEPARTMENT_LIST
    IS
    sql_stat VARCHAR2(32767);
    ret_code NUMBER;
    BEGIN
    -- SQL Statement for Drop-down List
    -- (must have two columns for label and value - both VARCHAR2)
    sql_stat := ' SELECT DEPARTMENT_NAME,TO_CHAR(DEPT_ID)'
    ||' FROM SCHEMA.DEPARTMENT';
    POPULATE_MY_LIST('BLOCK.DEPARTMENT_LIST',sql_stat,ret_code);
    END;
    2. Generic procedure:
    PROCEDURE POPULATE_MY_LIST
    (item_name VARCHAR2,
    sql_stat VARCHAR2,
    out_code OUT NUMBER)
    IS
    rg_id RECORDGROUP;
    rg_name VARCHAR2(100);
    ret_code NUMBER;
    item_id ITEM;
    BEGIN
         item_id := FIND_ITEM(item_name);
         IF ID_NULL(item_id) THEN
              out_code := -1;
              RETURN;
         END IF;
         --Creating Record Group with Unique Name
         rg_name := 'RG_'||SUBSTR(item_name,INSTR(item_name,'.',1)+1,LENGTH(item_name));
         --Checking Record Group Name for existance
         rg_id := FIND_GROUP(rg_name);
         --If Group does exist - delete it
         IF NOT ID_NULL(rg_id) THEN
              DELETE_GROUP(rg_id);
         END IF;
         --Creating Record Group
         rg_id := CREATE_GROUP_FROM_QUERY(rg_name,sql_stat);
    ret_code := POPULATE_GROUP(rg_id);
    IF (ret_code <> 0) THEN
         out_code := ret_code;
         RETURN;
    END IF;
    POPULATE_LIST(item_name,rg_id);
    IF NOT FORM_SUCCESS THEN
         out_code := -2;
         RETURN;
    ELSE
    out_code := 0;     
    END IF;
    DELETE_GROUP(rg_id);
    END;
    Hope it help.
    Dmitry

Maybe you are looking for

  • Can't remember my iphone password - what do i do?

    I input a new password in my phone. When I went to open it up later the new password did not work. What do I do?

  • Business Process: Fork: Error when mapping

    Hello everybody, I am not sure if SXMB_MONI_BPE is throwing me an irritating error? I have an integration process starting with ONE receive step. After the receive step I have a fork (NOT in a block), with two branches! In every branch there is first

  • DMEE tree format tab delimited - How?

    All I have to configure (trx DMEE) a 'data medium exchange' format that is going to be used for outgoing payments. One of the requirements is that it has to be 'tab delimited'. On the tab 'Format attributes' in trx DMEE you specifiy if fields have fi

  • Messages on Mavericks won't open after 10.9.2 upgrade

    Hi, I upgraded to 10.9.2 this morning and now when I try tro open Messages I get the following Box. "The last time you opened Messages, it unexpectedly quit while reopening windows. Do you want to try to reopen its windows again?" How can I fix this?

  • VALIDATE_WITH_CONTEXT mental block ...

    Hi, I just do not see the problem. Maybe someone could tell me the problem here: This returns TRUE: select sdo_geom.validate_geometry_with_context( MDSYS.SDO_GEOMETRY(2002,2236,null,MDSYS.SDO_ELEM_INFO_ARRAY(1,4,4,1,2,2,9,2,1,13,2,2,17,2,1),MDSYS.SDO