Set multi select-options

Hi,
Do you know how to set multi select-options in ABAP, i know i can use default to set single value. but is it possible set multi value for select-options. Thanks

Hi ,
Just like Rich Heilman said,
with a litle modification:
select-options: s_datum for sy-datum.
initialization.
s_datum-sign = 'I'.
s_datum-option = 'BT'.
s_datum-low = sy-datum.        s_datum-high = sy-datum+30.    append s_datum.
s_datum-low = sy-datum + 1.  s_datum-high = sy-datum+31.    append s_datum.
s_datum-low = sy-datum + 2.  s_datum-high = sy-datum+32.    append s_datum.
s_datum-low = sy-datum + 3.  s_datum-high = sy-datum+33.    append s_datum.
Regards,

Similar Messages

  • Custom File Info Panel Multi select options

    Hi,
    I have created a custom file info panel and working on simple properties.
    it does not have options for provisioning a multi select list box. Say for example, I want to select multiple values from the dropdown values.
    How should i do it? Any help is much appreciated.
    Thanks,
    Sriram

    Hi,
    Following is my sample property file. I want to make the property "Line Year" to be multiselect.
    <xmp_definitions>
    </xmp_schema prefix='x' namespace='x....'
                      <xmp_property name='LineYear' category='external' label='Line Year' type='closedchoice' element_type='text'>
                                    <xmp_choice raw_value="2007" label="2007"/>
                                    <xmp_choice raw_value="2008" label="2008"/>
                                    <xmp_choice raw_value="2009" label="2009"/>
                    </xmp_property>
        </xmp_schema>
    </xmp_definitions>

  • How to set a select option's item as invisible (using a method code)

    Hi there,
    I need to hide parameters and select option fields, but Iu2019m using the select_option component to add all items to the layout using just one View Container Element.
    I could use to hide the View Container Element setting the property visible, but I need to hide fields with certain conditions. I also could add one View Container Element for each select option, but I have many... I wish I could make in other way.
    Iu2019ve checked the Definitions of the Interface IF_WD_SELECT_OPTIONS  and the Ulli Hoffmannu2019s book and I have found no help at all.
    Thanks in advance,
    Filipe Torres
    Edited by: Filipe Torres on Sep 15, 2008 12:34 AM

    Thank you, this helps but will solve just part of my problem. I'm using many views and to pass the values from those select options and parameters I just declare them in the first view... The other answer helps me more that shows how to remove one element. I was looking for a hide feature and not remove, but seems that I have to remove.

  • Is there a command for setting the selection option to be mandatory

    hi,
    i have a 4 select-option in my program, and i would set that, either one select option must be fill to execute the program. which mean, at least one field ( any select option) have to be enter, or else it will not run. is there a command to restrict on this?
    please help. thanks

    Check this sample
    TABLES : vbap.
    SELECT-OPTIONS : so_vbeln FOR vbap-vbeln,
                     so_posnr FOR vbap-posnr.
    AT SELECTION-SCREEN.
      IF NOT so_vbeln[] IS INITIAL OR
         NOT so_posnr[] IS INITIAL.
      ELSE.
        MESSAGE e000(ztest_gopi) WITH 'Atleast one shd be filled'.
      ENDIF.
    " OR You can do it this way also
    TABLES : vbap.
    SELECT-OPTIONS : so_vbeln FOR vbap-vbeln,
                     so_posnr FOR vbap-posnr.
    AT SELECTION-SCREEN.
      IF so_vbeln[] IS INITIAL AND
         so_posnr[] IS INITIAL.
        MESSAGE e000(ztest_gopi) WITH 'Atleast one shd be filled'.
      ENDIF.
    Regards
    Gopi

  • Table View MULTI SELECT option and Event handling problems

    Hello All,
    I am facing problem while giving miltselect option in a table view. When i mention multiselect attribute in Select option in table view, i am unable to select all the rows which i want to select,because i have an event onRowSelection event activated so when i select a row then it will automatically go to the event and i am unable to do multiple select.
    Can you guys pl tell me is there any way thtat i can put check boxes in a table column and by that i can get values of row seelct and can perform my subsequent SQL operation.
    Also i am not able to navigate in table view through BYPAGE or BYLINE option. When I click on navigate button then page got refreshed and i lost data.
    One more query guys , can you pl tell me how can i store my internal table values from one event for the another event. I have used EXport/Import but internal table values get refreshed as page got refreshed on event switching/selection.
    Please respond.

    hye rahul.
      as i told you my second solution, will help you . the values remain in the corresponding UI elements.
    For example , you have a drop down and table view. both will trigger events. bind the data of the table at drop down event and bind the dat of the drop down at table event.
    event = cl_htmlb_manager=>get_event( runtime->server->request ).
    CASE event->id.
    when 'dd1'.                   drop down event is fired.
    bind data for drop down
    dd ?= cl_htmlb_manager=>get_data(
                                          request = runtime->server->request
                                          name    = 'dropdown'
                                          id      = dd_id'           " name of the drop down id
    along with drop down bind data for table view
        tbv ?= cl_htmlb_manager=>get_data(
                                          request = runtime->server->request
                                          name    = 'tableView'
                                          id      = 'tbv_id'           " name of the table view
    when 'tbv_id'.                   drop down event is fired.
    bind data for drop down
    dd ?= cl_htmlb_manager=>get_data(
                                          request = runtime->server->request
                                          name    = 'dropdown'
                                          id      = dd_id'           " name of the drop down id
    along with drop down bind data for table view
        tbv ?= cl_htmlb_manager=>get_data(
                                          request = runtime->server->request
                                          name    = 'tableView'
                                          id      = 'tbv_id'           " name of the table view
    This is how data should be binded in case of Stateless application. All the UI elemets must b binded again.. as the global data is refresed again.
    Hope this helps.
    Regards,
    Imran.

  • How to set multi select by script to a list box.

    Hi All,
    I have a list box with multiple select on the form with list (Say A,B,C,D,E,F,G ..)
    When I select A,C,E ans say this.RawValue I get A,C,E separated by carrage returns.
    When i submit the form in my Fm I get A#C#E its all fine.
    Now when the form is openend for the 2nd time to update values I get the value as A,C,E separated by carrage return thats fine too.
    Now i need to set these 3 values as selected by default so i had some java script in form ready.
    Where i iterate tru these list match the entries in the dropdown its fine untill here.
    this.setItemState(index,true)
    is the code to set them as selected but when i do only the 1st found is set to selected not the remaining ones.
    Am i doing something wrong here, please let me know with your suggestions.
    below is my script.
    var ddValue =  this.rawValue;
    ddValue = ddValue.replace("#","\n");
    var ddArray = ddValue.split("\n");
    var ddLen = ddArray.length;
    var textValue = "";
    GM_INTAKE_STRUCTURE.sf80.sfItemBuilder.sfHeaderConditions.dlExpenseType.clearItems;
    GM_INTAKE_STRUCTURE.sf80.sfRequestSummary.dlItem.clearItems;
    for(var i = 0;i<ddLen;i++){
         for(var j = 0;j<this.length;j++){
              if(this.getSaveItem(j) == ddArray<i>){
                   this.setItemState(j,true);                
                   GM_INTAKE_STRUCTURE.sf80.sfItemBuilder.sfHeaderConditions.dlExpenseType.addItem(this.items.nodes.item(j).value,this.getSaveItem(j));
    Thanks & Regards,
    Sai

    Hi Sai,
         The replace function is only replacing the first occur of #, not all of them. But you don't even need to replace the # before you do the split, just change your first lines to split directly with the # character. Your code should look as follow:
    var ddValue =  this.rawValue;
    var ddArray = ddValue.split("#");
    var ddLen = ddArray.length;
    var textValue = "";
    GM_INTAKE_STRUCTURE.sf80.sfItemBuilder.sfHeaderConditions.dlExpenseType.clearItems;
    GM_INTAKE_STRUCTURE.sf80.sfRequestSummary.dlItem.clearItems;
    for(var i = 0;i<ddLen;i++){
         for(var j = 0;j<this.length;j++){
              if(this.getSaveItem(j) == ddArray<i>){
                   this.setItemState(j,true);                
    GM_INTAKE_STRUCTURE.sf80.sfItemBuilder.sfHeaderConditions.dlExpenseType.addItem(this.items.nodes.item(j).value,this.getSaveItem(j));
    Best regards, Aldo.
    Any comments and feedback are welcome.

  • Multi-select options in Dreamweaver form?

    Hi folks,
    I am creating a booking form that is hosted on a secure site for credit card transmission. This is the form customers complete https://supersecure.co.nz/users/9ba5/215/form_walks_retail.html and they are directed from this page: http://www.qtnz.co.nz/2013
    A typical booking would be 2 adults and perhaps 1 or 2 children and they'd likely choose only one of the activity options.
    Previously I've used pick lists for customers to choose the number of places they are booking but my clients' product list has grown and it's very tedious having to create individual fields and labels for each possible activity that can be booked.
    I am stuck with this particular method of collating credit card data, so an e-commerce site is not really an option.
    As folks here are far more experienced than I in DW forms I'd be grateful if anyone could suggest an easier way of taking bookings through a Dreamweaver form.
    Thanks in advance for advice
    Jo

    Same question. Any ideas?

  • Multi select option required in Calendar LOV

    Dear All,
    I have a requirement to select multiple dates in a calendar LOV. Upon selecting the dates, all the dates should be inserted into a table. Is there any such tool/utility available?
    Regards,
    Balaji

    use the standard calendar from the otn-forms-examples and implement your special functionality in those codes. That seems to be very easy

  • Problem to convert a optionset into multi selection picklist on crm 2013

    Hey I meet a problème on my development see my result :
    link : https://social.microsoft.com/Forums/getfile/652331
    a multiple select list on my crm 2013 I do this process on this forum :
    link : https://social.microsoft.com/Forums/en-US/2db47a59-165d-40c9-b995-6b3262b949eb/how-to-convert-a-optionset-into-multi-selection-picklist-in-crm-2011-using-javasacript?forum=crmdevelopment
    my development :
    // var_sc_optionset >> Provide schema-name for Option Set field
    // var_sc_optionsetvalue >> Provide schema-name for field which will store the multi selected values for Option Set
    // OS >> Provide Option Set field object
    // OSV >> Provide text field object which will store the multi selected values for Option Set
    //Method to convert an optionset to multi select Option Set
    function ConvertToMultiSelect(var_sc_optionset, var_sc_optionsetvalue, OS, OSV)
    if( OS != null && OSV != null )
    OS.style.display = "none";
    Xrm.Page.getControl(var_sc_optionsetvalue).setVisible(false);
    // Create a DIV container
    // var addDiv = document.createElement("<div style='overflow-y:auto; color:#000000; height:160px; border:1px #6699cc solid; background-color:#ffffff;' />");
    var addDiv = document.createElement("div");
    addDiv.style.overflowY = "auto";
    addDiv.style.height = "160px";
    addDiv.style.border = "1px #6699cc solid";
    addDiv.style.background = "#ffffff";
    addDiv.style.color = "#000000";
    OS.parentNode.appendChild(addDiv);
    // Initialise checkbox controls
    for( var i = 1; i < OS.options.length; i++ )
    var pOption = OS.options[i];
    if( !IsChecked( pOption.text , OS, OSV) ){
    // var addInput = document.createElement("<input type='checkbox' style='border:none; width:25px; align:left;' />" );
    var addInput = document.createElement("input" );
    addInput.setAttribute("type","checkbox");
    addInput.setAttribute("style","border:none; width:25px; align:left;");
    else {
    // var addInput = document.createElement("<input type='checkbox' checked='checked' style='border:none; width:25px; align:left;' />" );
    var addInput = document.createElement("input" );
    addInput.setAttribute("type","checkbox");
    addInput.setAttribute("checked","checked");
    addInput.setAttribute("style","border:none; width:25px; align:left;");
    // var addLabel = document.createElement( "<label />");
    var addLabel = document.createElement( "label");
    addLabel.innerText = pOption.text;
    // var addBr = document.createElement( "<br />"); //it's a 'br' flag
    var addBr = document.createElement( "br"); //it's a 'br' flag
    OS.nextSibling.appendChild(addInput);
    OS.nextSibling.appendChild(addLabel);
    OS.nextSibling.appendChild(addBr);
    ///////Supported functions
    // Check if it is selected
    function IsChecked( pText , OS, OSV)
    if(OSV.value != "")
    var OSVT = OSV.value.split(";");
    for( var i = 0; i < OSVT.length; i++ )
    if( OSVT[i] == pText )
    return true;
    return false;
    // var_sc_optionsetvalue >> Provide schema-name for field which will store the multi selected values for Option Set
    // OS >> Provide Option Set field object
    // Save the selected text, this field can also be used in Advanced Find
    function OnSave(OS, var_sc_optionsetvalue)
    var getInput = OS.nextSibling.getElementsByTagName("input");
    var result = '';
    for( var i = 0; i < getInput.length; i++ )
    if( getInput[i].checked)
    result += getInput[i].nextSibling.innerText + ";";
    //save value
    control = Xrm.Page.getControl(var_sc_optionsetvalue);
    attribute = control.getAttribute();
    attribute.setValue(result);
    I have to do 2 field one is option list field and the second is textfield, 
    option list field : new_books
    textfiled          : new_picklistvalue
    my js is on onload event see : 
    link : https://social.microsoft.com/Forums/getfile/652333
    thanks you for you'r help 

    Hey I meet a problème on my development see my result :
    link : https://social.microsoft.com/Forums/getfile/652331
    a multiple select list on my crm 2013 I do this process on this forum :
    link : https://social.microsoft.com/Forums/en-US/2db47a59-165d-40c9-b995-6b3262b949eb/how-to-convert-a-optionset-into-multi-selection-picklist-in-crm-2011-using-javasacript?forum=crmdevelopment
    my development :
    // var_sc_optionset >> Provide schema-name for Option Set field
    // var_sc_optionsetvalue >> Provide schema-name for field which will store the multi selected values for Option Set
    // OS >> Provide Option Set field object
    // OSV >> Provide text field object which will store the multi selected values for Option Set
    //Method to convert an optionset to multi select Option Set
    function ConvertToMultiSelect(var_sc_optionset, var_sc_optionsetvalue, OS, OSV)
    if( OS != null && OSV != null )
    OS.style.display = "none";
    Xrm.Page.getControl(var_sc_optionsetvalue).setVisible(false);
    // Create a DIV container
    // var addDiv = document.createElement("<div style='overflow-y:auto; color:#000000; height:160px; border:1px #6699cc solid; background-color:#ffffff;' />");
    var addDiv = document.createElement("div");
    addDiv.style.overflowY = "auto";
    addDiv.style.height = "160px";
    addDiv.style.border = "1px #6699cc solid";
    addDiv.style.background = "#ffffff";
    addDiv.style.color = "#000000";
    OS.parentNode.appendChild(addDiv);
    // Initialise checkbox controls
    for( var i = 1; i < OS.options.length; i++ )
    var pOption = OS.options[i];
    if( !IsChecked( pOption.text , OS, OSV) ){
    // var addInput = document.createElement("<input type='checkbox' style='border:none; width:25px; align:left;' />" );
    var addInput = document.createElement("input" );
    addInput.setAttribute("type","checkbox");
    addInput.setAttribute("style","border:none; width:25px; align:left;");
    else {
    // var addInput = document.createElement("<input type='checkbox' checked='checked' style='border:none; width:25px; align:left;' />" );
    var addInput = document.createElement("input" );
    addInput.setAttribute("type","checkbox");
    addInput.setAttribute("checked","checked");
    addInput.setAttribute("style","border:none; width:25px; align:left;");
    // var addLabel = document.createElement( "<label />");
    var addLabel = document.createElement( "label");
    addLabel.innerText = pOption.text;
    // var addBr = document.createElement( "<br />"); //it's a 'br' flag
    var addBr = document.createElement( "br"); //it's a 'br' flag
    OS.nextSibling.appendChild(addInput);
    OS.nextSibling.appendChild(addLabel);
    OS.nextSibling.appendChild(addBr);
    ///////Supported functions
    // Check if it is selected
    function IsChecked( pText , OS, OSV)
    if(OSV.value != "")
    var OSVT = OSV.value.split(";");
    for( var i = 0; i < OSVT.length; i++ )
    if( OSVT[i] == pText )
    return true;
    return false;
    // var_sc_optionsetvalue >> Provide schema-name for field which will store the multi selected values for Option Set
    // OS >> Provide Option Set field object
    // Save the selected text, this field can also be used in Advanced Find
    function OnSave(OS, var_sc_optionsetvalue)
    var getInput = OS.nextSibling.getElementsByTagName("input");
    var result = '';
    for( var i = 0; i < getInput.length; i++ )
    if( getInput[i].checked)
    result += getInput[i].nextSibling.innerText + ";";
    //save value
    control = Xrm.Page.getControl(var_sc_optionsetvalue);
    attribute = control.getAttribute();
    attribute.setValue(result);
    I have to do 2 field one is option list field and the second is textfield, 
    option list field : new_books
    textfiled          : new_picklistvalue
    my js is on onload event see : 
    link : https://social.microsoft.com/Forums/getfile/652333
    thanks you for you'r help 

  • How to convert a optionset into multi selection picklist in crm 2011 using javasacript??

    hi,
    where user want to select not only one but multiple value
    from a pick list. I tried  examples but it shows some errors.
    How  to do it??

    Hey I meet a problème on my development see my result :
    link : https://social.microsoft.com/Forums/getfile/652331
    a multiple select list on my crm 2013 I do this process on this forum :
    link : https://social.microsoft.com/Forums/en-US/2db47a59-165d-40c9-b995-6b3262b949eb/how-to-convert-a-optionset-into-multi-selection-picklist-in-crm-2011-using-javasacript?forum=crmdevelopment
    my development :
    // var_sc_optionset >> Provide schema-name for Option Set field
    // var_sc_optionsetvalue >> Provide schema-name for field which will store the multi selected values for Option Set
    // OS >> Provide Option Set field object
    // OSV >> Provide text field object which will store the multi selected values for Option Set
    //Method to convert an optionset to multi select Option Set
    function ConvertToMultiSelect(var_sc_optionset, var_sc_optionsetvalue, OS, OSV)
    if( OS != null && OSV != null )
    OS.style.display = "none";
    Xrm.Page.getControl(var_sc_optionsetvalue).setVisible(false);
    // Create a DIV container
    // var addDiv = document.createElement("<div style='overflow-y:auto; color:#000000; height:160px; border:1px #6699cc solid; background-color:#ffffff;' />");
    var addDiv = document.createElement("div");
    addDiv.style.overflowY = "auto";
    addDiv.style.height = "160px";
    addDiv.style.border = "1px #6699cc solid";
    addDiv.style.background = "#ffffff";
    addDiv.style.color = "#000000";
    OS.parentNode.appendChild(addDiv);
    // Initialise checkbox controls
    for( var i = 1; i < OS.options.length; i++ )
    var pOption = OS.options[i];
    if( !IsChecked( pOption.text , OS, OSV) ){
    // var addInput = document.createElement("<input type='checkbox' style='border:none; width:25px; align:left;' />" );
    var addInput = document.createElement("input" );
    addInput.setAttribute("type","checkbox");
    addInput.setAttribute("style","border:none; width:25px; align:left;");
    else {
    // var addInput = document.createElement("<input type='checkbox' checked='checked' style='border:none; width:25px; align:left;' />" );
    var addInput = document.createElement("input" );
    addInput.setAttribute("type","checkbox");
    addInput.setAttribute("checked","checked");
    addInput.setAttribute("style","border:none; width:25px; align:left;");
    // var addLabel = document.createElement( "<label />");
    var addLabel = document.createElement( "label");
    addLabel.innerText = pOption.text;
    // var addBr = document.createElement( "<br />"); //it's a 'br' flag
    var addBr = document.createElement( "br"); //it's a 'br' flag
    OS.nextSibling.appendChild(addInput);
    OS.nextSibling.appendChild(addLabel);
    OS.nextSibling.appendChild(addBr);
    ///////Supported functions
    // Check if it is selected
    function IsChecked( pText , OS, OSV)
    if(OSV.value != "")
    var OSVT = OSV.value.split(";");
    for( var i = 0; i < OSVT.length; i++ )
    if( OSVT[i] == pText )
    return true;
    return false;
    // var_sc_optionsetvalue >> Provide schema-name for field which will store the multi selected values for Option Set
    // OS >> Provide Option Set field object
    // Save the selected text, this field can also be used in Advanced Find
    function OnSave(OS, var_sc_optionsetvalue)
    var getInput = OS.nextSibling.getElementsByTagName("input");
    var result = '';
    for( var i = 0; i < getInput.length; i++ )
    if( getInput[i].checked)
    result += getInput[i].nextSibling.innerText + ";";
    //save value
    control = Xrm.Page.getControl(var_sc_optionsetvalue);
    attribute = control.getAttribute();
    attribute.setValue(result);
    I have to do 2 field one is option list field and the second is textfield, 
    option list field : new_books
    textfiled          : new_picklistvalue
    my js is on onload event see : 
    link : https://social.microsoft.com/Forums/getfile/652333
    thanks you for you'r help 

  • Passing Multiple Values from Multi Select

    Hi,
    My requirement is simple. I have created a simple Multi Select Option in parameter form and i want to send multiple selected values from the multi select option (in parameter form) to reports.
    eg:
    I want to send multiple countries code as input .........'US', 'CA', 'IND', 'UK'
    Can i do it in Oracle 6i reports, Thanks in Advance.
    Regards,
    Asgar

    Hi Thanks Again,
    For such a nice response. I got the Lexical Where condition properly running but still getting problems in catching the multiple values to be passed from form. just i will give u an insight of wat i have done:
    SQL:
    SELECT ALL FROM EMPLOYEES &cond_1* -- Working FIne
    in my Html Parameter Form i have an Multi Select component (the Problem is here) it is not passing more than i value from the form once i am accessing it from web or running it in paper report. In paper report layout it is not allowing me to select more than one value. but in HTML it is allowing to select multiple values but at the server end (After Parameter Form Trigger) it is giving a single value not multiple values.
    In PL/SQL when i checking the length of country_id i m getting it as one.
    Here is my SQL code
    srw.message(10, LENGTH(:country_id_1));
    :cond_1 := 'where country_id = '''|| :country_id_1 ||'''';
    This is passing the condition properly to SQL but only with single value but i want to pass multiple values
    I am struck in this+_
    WHERE CONTRY_COLUMN IN ('USA','UAE') -- This variable you have to pass from you form...
    Here as you said you gave multiple selection in your parameter form to generate report. So before generation report just prepare variable like this as it is bold above.
    and pass parameter through your runtime form to the report as you pass the normal parameter...liket this i gave you example...
    ADD_PARAMETER(PARAMETER_LIST_NAME,'P_CONT_PARAM',TEXT_PARAMETER,vString);
    Sorry for troubling you for a small thing but please help me to solve this issue.
    Thanks Again............
    Asgar.

  • How can I re-display my selected option?

    In my jsp, I gain option values for a list of 'types' and 'names'
    If the currentType = null I do not show the form that accepts the 'names'.
    When a type is selected the Action class calls the getMethod in the ActionForm
    and upon success returns to the jsp page and presents the 'name' form.
    Unfortunately the 'type' form redisplays the first type in the list and not the
    currentType.
    Question. How can I set the selected option in my form to display the currentType?
    <!-- Access session bean for picklist types -->
    <jsp:useBean
    id="typesBean"
    scope="session"
    class="com.aaa.zzz.refdata.beans.CPartyTypesBean" >
    <jsp:setProperty name="typesBean" property="*" />
    </jsp:useBean>
    <%
    CPartyTypesBean typeBean = (CPartyTypesBean) session.getValue("typesBean");
    String[] PicklistTypes = typeBean.getTypes();
    %>
    <!-- Access Form Bean (ActionForm) for current Name & Type -->
    <jsp:useBean
    id="pb"
    scope="session"
    class="com.aaa.zzz.refdata.beans.CPartyPicklistBean" >
    </jsp:useBean>
    <jsp:setProperty name="pb" property="*" />
    <%
    String currentType = pb.getType();
    String currentName = pb.getName();
    %>
    <html:form action="/typeAction" focus="type">
    <table>
    <tr>
    <td WIDTH="20%">
    Picklist Type
    </td>
    <td WIDTH="30%">
    <select name="type">
    <%
    for(int i=0; i<PicklistTypes.length; i++)
    out.println("<option>" + PicklistTypes[i] + "</option>");
    %>
    </select>
    </td>
    <td WIDTH="20%">
    <html:submit property="submit" value="GetType"/>
    </td>
    <td WIDTH="30%">
    </td>
    </tr>
    </table>
    </html:form>
    <%
    if (currentType != null)
    %>
    <html:form action="/nameAction" focus="name">

    Thanks Beattris, I guess 'selected' is the obvious answer but what I was looking for was
    how to apply 'selected' to the loop that prints my options.
    However I figured it out and did this:
    <%
    for(int i=0; i<PicklistTypes.length; i++)
    String sel = null;
    if(currentType != null && currentType.compareTo(PicklistTypes)==0)
    sel = " SELECTED>";
    else
    sel = ">";
    out.println("<option value=" + PicklistTypes[i] + sel + PicklistTypes[i]+"</option>");
    %>

  • Select-options in display mode

    Hi
    How to set the SELECT-OPTIONS in display mode by default
    regards
    Srinivas

    hiii
    for every LOW and HIGH value of select option you can use a code like given below..
    First initialize your select option with some values then use following code
    AT SELECTION-SCREEN OUTPUT .
      IF s_docno IS NOT INITIAL .
        LOOP AT SCREEN.
          IF screen-name CS 's_docno'.
           screen-input = 0.
            MODIFY SCREEN.
          ENDIF.                           " IF screen-name CS 'p_docno'.
        ENDLOOP.                           " LOOP AT SCREEN.
    regards
    twinkal

  • Select Options use in ALV Report in ABAP Webdynpro

    Hello Experts,
    I Already Done ALV Report In webdynpro with use of view Container UI element.But i do not know ALV  report with help of select option.so
    Kindly Give Me simple Example of Use in select Option In ALV.
    Reply ASAP.
    Regards,
    Ameya Karadkhedkar

    First you need to add the component WDR_SELECT_OPTIONS to the tab "Used components" of your Web Dynpro component and then also in the properties tab of your view. In the layout you need to create another view container and embed the view WND_SELECTION_SCREEN of the new used component to it.
    Then in the WDDOINIT method of your view you can write this code (where SEL_OPT is the given name for the used component) in order to set the select option (This example is a select option for a date):
    DATA: lo_cmp_usage           TYPE REF TO if_wd_component_usage,
          lo_interfacecontroller TYPE REF TO iwci_wdr_select_options,
          lo_r_helper_class      TYPE REF TO if_wd_select_options,
          rt_range_date          TYPE REF TO data.
    * Instantiate used component WDR_SELECT_OPTIONS (SEL_OPT)
    lo_cmp_usage = wd_this->wd_cpuse_sel_opt( ).
    IF lo_cmp_usage->has_active_component( ) IS INITIAL.
      lo_cmp_usage->create_component( ).
    ENDIF.
    * Call method in used controller
    lo_interfacecontroller = wd_this->wd_cpifc_sel_opt( ).
    lo_r_helper_class = lo_interfacecontroller->init_selection_screen( ).
    * Create select option for the date
    CALL METHOD lo_r_helper_class->create_range_table
      EXPORTING
        i_typename    = 'DATS'
      RECEIVING
        rt_range_table = rt_range_date.
    CALL METHOD lo_r_helper_class->add_selection_field
      EXPORTING
        i_id          = 'DATS'
        it_result     = rt_range_date
        i_read_only   = ABAP_FALSE.
    * Hide unnecessary buttons
    CALL METHOD lo_r_helper_class->set_global_options
      EXPORTING
        i_display_btn_cancel  = abap_false
        i_display_btn_check   = abap_false
        i_display_btn_reset   = abap_false
        i_display_btn_execute = abap_false.
    Finally you need to write the following code in the action of the button in order to fetch the range table selected by the user.
    DATA: lo_cmp_usage            TYPE REF TO if_wd_component_usage,
          lo_interfacecontroller  TYPE REF TO iwci_wdr_select_options,
          lo_r_helper_class       TYPE REF TO if_wd_select_options,
          rt_date                 TYPE REF TO data.
    FIELD-SYMBOLS: <fs_date> TYPE table.
    * Instantiate used component WDR_SELECT_OPTIONS (SEL_OPT)
    lo_cmp_usage = wd_this->wd_cpuse_sel_opt( ).
    IF lo_cmp_usage->has_active_component( ) IS INITIAL.
      lo_cmp_usage->create_component( ).
    ENDIF.
    * Call method in used controller
    lo_interfacecontroller = wd_this->wd_cpifc_sel_opt( ).
    lo_r_helper_class = lo_interfacecontroller->init_selection_screen( ).
    * get selected range of inspections date
    CALL METHOD lo_r_helper_class->get_range_table_of_sel_field
      EXPORTING
        i_id          = 'DATS'
      RECEIVING
        rt_range_table = rt_date.
    ASSIGN rt_date->* TO <fs_date>.
    Then you can use the value that is assigned to the field symbol <fs_date> to continue with your ALV.

  • Making input select option or input field mandatory....

    Hello Gurus,
    I have been through some material to create select options in web dynpro ABAP. Now I want to make one of the fields mandatory so that if user executes it without filling data in that filed, it gives error message or enforces user to input in the manadtory field.
    I know how to do this in ABAP but how do I achieve the same in ABAP webdynpro ?
    Please help.
    Regards,
    Jainam.

    Hi ,
    Set i_obligatory parameter as X. This will set the select options as mandatory and standard error message will popup in case it is not filled.
    wd_this->m_handler->add_selection_field(
      i_id = 'S_CARR_ID'
      it_result = lt_range_table
    *  i_obligatory = 'X'   ,  " To make it mandatory

Maybe you are looking for

  • Using columns of user defined types

    Can anyone help me display data from a column within a table which is of a user defined type - a object with 4 elements . Discoverer wont currently display the data - it says a MAP or ORDER method is required. The type is declared as : create or repl

  • How do I connect to a DB2 database from Oracle 10G on linux?

    Hi I have tryed to connect to a DB2 database from oracle 10 G on linux. I have installed unixODBC and a db2 odbc driver. I can connect to the db2 using isql, but oracle comes with this error: select * from testtable@acc_spc_gr2 ERROR at line 1: ORA-2

  • Lenovo G50 NOT plugged in, but 'charging'.

    I just bought a new Lenovo G50 about a month ago. The only strange problem I have picked up in the last 2 weeks, is that even when my notebook is NOT plugged into the charger, it still indicates that it is charging from an incompatible power source.

  • Re: Is it possible to change row colors on array fields ors

    HI Martin! Yes, it is possible to change row colors on array fields. I have attached a PEX (tools.pex) which has an object which changes FillColor and PenColor for Arrays. The PEX has it's own test window, so you can try various combinations. (There

  • Podcast show up on iPod uninvited

    All my podcasts are copied to my iPod, if I set them to or not. Once on the iPod, they are not readily available. I have to dive into genres or playlist to find them. Unlike all the other similar issue I read on here, if I set a podcast to sync, it w