Adding data in a list box

Hi all,
I created a list-box on the selection-screen using
PARAMETERS p_mtart type mtart AS LISTBOX VISIBLE LENGTH 20
But, I don't find a way to add data to this list-box.
Please help me.
Regards,
Saurabh Buksh.

Hi,
Sorry to bother you.
I solved it.
Regards,
Saurabh Buksh.

Similar Messages

  • How to add data into a List box

    CS3 SDk:Windows<br /><br />Hi all,<br />I am trying to add  data into a basic List box in CS3??<br /><br />// .fr<br />GenericPanelWidget<br />     (<br />     // CControlView properties<br />     kInvalidWidgetID, // widget ID<br />     kPMRsrcID_None, // PMRsrc ID<br />     kBindNone, // frame binding<br />     Frame(0,0,250,90) // left, top, right, bottom<br />     kTrue, // visible<br />     kTrue, // enabled<br />     // GroupPanelAttributes properties<br />     "", // header widget ID<br />     { <br />     <br />     WidgetListBoxWidgetN<br />     (<br />     kWFPListBoxWidgetID, kSysListBoxPMRsrcId, // WidgetId,RsrcId<br />     kBindAll, // Frame binding<br />     Frame(0,0,250,90) // Frame<br />     kTrue, kTrue, // Visible, Enabled<br />     1,0, // List dimensions<br />     19, // Cell height<br />     1, // Border width<br />     kFalse,kTrue, // Has scroll bar (h,v)<br />     kTrue, // Multiselection<br />     kTrue, // List items can be reordered<br />     kTrue, // Draggable to new/delete buttons<br />     kFalse, // Drag/Dropable to other windows<br />     kTrue, // An item always has to be selected<br />     kFalse,// Don't notify on reselect<br />     kFalse, <br />     {               <br />     }     <br />                    <br />),<br />},<br />),<br /><br />//-------ID.h--------<br />DECLARE_PMID(kWidgetIDSpace, kWFPListBoxWidgetID, kWFPPrefix + 2)<br /><br />//observer.cpp-----------WFPDialogObserver::Update<br /><br />//get currently selected/active widget <br />WidgetID theSelectedWidget = controlView->GetWidgetID();<br /><br />// ist it the text edit field? <br />if (theSelectedWidget == kWFPInsertButtonWidgetID && theChange == kTrueStateMessage) <br />{ <br /><br />IControlView* listBox = panelControlData->FindWidget(kWFPListBoxWidgetID);<br /><br />InterfacePtr<IListControlData> listControlData(listBox, UseDefaultIID()); <br /><br />//Insert the string into listbox <br />PMString strText = dialogCtrl->GetTextControlData(kWFPTextEditBoxWidgetID); <br /><br />// obviously there can't be a translation for text entered by user <br />strText.SetTranslatable(kFalse);<br />listControlData->Add(strText,kWFPTextEditBoxWidgetID); <br />dialogCtrl->SetTextControlData(kWFPTextEditBoxWidgetID, ""); <br />break;      <br /><br />I am not able to Add items into list box.<br /><br />I tried based on Discussion <br />http://www.adobeforums.com/webx/.3bc43877<br /><br />but not able to locate  SDKListBoxHelper file .it is not available in SDK.<br /><br />Please ,<br />Tell me Where I am going wrong.<br /><br />Thanks,<br />Adil

    resource VSPDialogWidget (kSDKDefDialogResourceID + index_enUS)
         __FILE__,
         __LINE__,
         kVSPDialogWidgetID, // WidgetID
         kPMRsrcID_None, // RsrcID
         kBindNone, // Binding
         Frame(5,0,491,266) // Frame (l,t,r,b)
         kTrue,
         kTrue, // Visible, Enabled
         kVSPDialogTitleKey, // Dialog name
              DefaultButtonWidget
                   kOKButtonWidgetID, // WidgetID
                   kSysButtonPMRsrcId, // RsrcID
                   kBindNone, // Binding
                   Frame(9,234,89,254) // Frame (l,t,r,b)
                   kTrue,
                   kTrue, // Visible, Enabled
                   kSDKDefOKButtonApplicationKey,  // Button text
              CancelButtonWidget
                   kCancelButton_WidgetID, // WidgetID
                   kSysButtonPMRsrcId, // RsrcID
                   kBindNone, // Binding
                   Frame(394,234,474,254) // Frame (l,t,r,b)
                   kTrue,
                   kTrue, // Visible, Enabled
                   kSDKDefCancelButtonApplicationKey, // Button name
                   kTrue,  // Change to Reset on option-click.
              WLBCmpListBox   //Tree view
                   kWLBCmpListBoxWidgetID, kPMRsrcID_None,     // WidgetId, RsrcId
                   kBindAll,                                                       // Frame binding
                   Frame(299,49,475,170)           // Frame
                   kTrue, kTrue,                                             // Visible, Enabled
                   kTrue,                               // EraseBeforeDraw
                   kInterfacePaletteFill,           // InterfaceColor
                   kHideRootNode | kDrawEndLine,     // Options. Display root node
                   kFalse,          // Use H Scroll bar
                   kTrue,          // Use V scroll bar
                   20,               // fVScrollButtonIncrement
                   20,               // fVThumbScrollIncrement
                   0,               // fHScrollButtonIncrement
                   0,               // fHThumbScrollIncrement
                   2,               // Items selectable, 0 = No Selection, 1 = Single Selection, 2 = Multiple Selection
                   kFalse,          // Allow children from multiple parents to be selected
                   kTrue,          // Allow discontiguous selection
                        //The tree view is dynamically created.          
    // added to support the list elements in the list box
    resource LocaleIndex (kWLBCmpListElementRsrcID)
         kViewRsrcType,
              kWildFS, k_Wild, kWLBCmpListElementRsrcID + index_enUS
    resource WLBCmpNodeWidget (kWLBCmpListElementRsrcID + index_enUS)
         __FILE__, __LINE__,
         kWLBCmpListParentWidgetId, kPMRsrcID_None,     // WidgetId, RsrcId
         kBindLeft | kBindRight,               // Frame binding
         Frame(0, 0, 194, 20),               // Frame
         kTrue, kTrue,                         // Visible, Enabled
         "",                                        // Panel name
                   // Just a info-static text widget with about-box text view to get white bg.
              WLBCmpTextWidget
                   kWLBCmpTextWidgetID, kPMRsrcID_None,          // WidgetId, RsrcId
                   kBindLeft | kBindRight,                                        // Frame binding
                   Frame(45,1,194,18)                                             // Frame
                   kTrue, kTrue, kAlignLeft,kEllipsizeEnd                    // Visible, Enabled, Ellipsize style
                   "",                                                                 // Initial text
                   0,                                                                 // Associated widget for focus
                   kPaletteWindowSystemScriptFontId,                         // default font
                   kPaletteWindowSystemScriptHiliteFontId,                    // for highlight state.
    If you still got problems, post you email here - I'll send you the complete project/code then.
    -Marc

  • Please help !!!! How to get data into dropdown list box

    Hi all,
    I want to display data from ResultSet object to drop down
    list box in my JSP form.
    How should I proceed ?
    Please help me what should I do ?
    Thanks for any help in advance.
    savdeep.

    dear hermione
    it depends on the compexity of the application
    i could also have suggested to use a JSP custom tag
    that can populate the values stored in a table. I
    guess u must have used that approach too.
    But why to make the things complicated when they can
    be done in an easier manner.
    The author seems to be a beginner and telling him to
    call Helper classes just to make a drop down is not
    at all feasible.
    what do u say?I believe it is best to start with a proper approach than finding quick solutions. Of course, JSTL sql tags allow you to execute queries within the JSP but they look cleaner in code.
    Certainly, if the OP is a beginner in JSP (presuming that he has some background of core Java and OOP), I don't see any reason why there should not be a separate class with a well-defined responsibility. This will help the OP develop a thinking towards designing a good solution rather than simply patching in bits of procedural code to get the job done. There is a difference in doing something and doing in properly. :)
    I suppose I am a little wary since I have been working too long maintaining code developed by others. A simple change in the requirement needs a lot of impact on several components.

  • Using LDAP data to populate list box

    Hi All,
    I have set up my authentication scheme reading the company LDAP using the dn string etc.
    I have created a table which holds all the staff details ( email etc ) but would like to have this data read directly from LDAP at login time or when required. The data ( username, email address, phone number and known-as credentials ) should be able to be used to populate list boxes.
    Any ideas ?
    Thanks - Robert @ london gov

    Hi Robert,
    The following thread might help give you a few ideas -
    Re: Cookie And LDAP
    I use that method to query my LDAP server and also use a materialized view (with timed refreshes) to be able to query information quicker than querying the LDAP server each time.

  • Declaring constant data in a list box - Dialog programming

    i need to declarare some constant data 1...4 in list box in dialog programming i have done some coding its not working here is the code, can you plz tell me whats wrong in the code non of the values are displaying in drop downbox.
    type-pools vrm.
    DATA: name TYPE vrm_id,
    list TYPE vrm_values,
    value LIKE LINE OF list.
    clear list.
    REFRESH LIST.
    value-key = '1'.
    value-text = 'Sales & Distribution'.
    append value to list.
    value-key = '2'.
    value-text = 'Material Management'.
    append value to list.
    value-key = '3'.
    value-text = 'Finance & Controlling'.
    append value to list.
    CALL FUNCTION 'VRM_SET_VALUES'
      EXPORTING
        id                    = 'LISTBOX1'
        values                = list
    EXCEPTIONS
      ID_ILLEGAL_NAME       = 1
      OTHERS                = 2
    IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
             WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.

    I think your code is correct onlybut the problem may be where
    you are passing the internal table to the FM 'VRM_SET_VALUES' ...
    Try to use the  following code..
    CALL FUNCTION 'VRM_SET_VALUES'
    EXPORTING
    id = 'LISTBOX1'
    values = list[]

  • How to put add formated data in multicolumn list box

    hello
    i am beginer of labview .
    my front panel is communicating with my hardware via serial port
    i am also getting a data also.
    i have fromated the answer also
    now i have to put in the multicolumn list box.
    e.g.
    my serial port string is  :001 01 20 23 45 45 00 05 06 00 00
    Formated string  01 20:23:45/45:00:05 06 00 00
    now above formated string i have to add in the multicolum listbox
    1st column 01  
    2nd column 20:23:45/45:00:05
    3rd column 06
    4th column 00
    5th column 00
    i hope you people help me
    thanks
    Lokesh

    A couple of mistakes.
    You initialize an array of 5 records with 10 elements instead of vice versa.
    Dennis is right, use "spreadsheet string to array" instead. Here's a quick draft (note that the delimiter is set to \'codes, it's a space constant)
    Is this loop interactive, i.e. does it need to update the records as the arrive with each iteration? If this is not the case, you should update the ItemNames only once after the loop has finished. For example as follows.
    LabVIEW Champion . Do more with less code and in less time .
    Attachments:
    AddRecords.png ‏8 KB
    addrecords2.png ‏7 KB

  • Adding element in a List box

    How do we add an element to an existing List box in swings?

    Read this section from the Swing tutorial on [url http://java.sun.com/docs/books/tutorial/uiswing/components/list.html]How to Use Lists.

  • Remaining Information after populating data in a list box

    Hi Guys,
    I have a small problem. Actually  I thought everything works perfect but as i saved or sent the form and opened it again the populated information was gone. I was shocked.
    I give you short function of my form.
    I type in texfield "Type" "a" or "b" a dropdown list with A, B, C appears. If I select A ,B or C or all of them then this information appears in a list box. that's perfect so far, but when I save this pdf file or send it to someone and open it, then the selected information is gone. this is horrible!
    Does anyone know what's going on wrong??
    I think the information should remain otherwise the function doesnt make sense.
    I appreciate it a lot if someone can help me to solve this problem!
    Thanks in advance!
    Diana

    You can assign the xfa.event.newText to a variable then you can reuse the var as required and you can set each of the listboxes according. The code would look something like this:
    var ListBoxSelection = xfa.event.newText;
    Com.addItem(ListBoxSelection);
    Com1.addItem(ListBoxSelection);
    Or I have completly misunderstood why you cannot set both ListBoxes.
    paul

  • Adding Date to Placeholder List

    Hi All-I am using BO 4.1 SP2 and Crystal 2013.While scheduling report thru bi launchpad there is an option to specify destination to email/file location.If you choose either one of the option you can see follow.In this Add placeholder,datetime option is available but there is NO date option.Is there a way i can add date to this placeholder list.Thanks.

    It looks like this idea over at the Idea Place is what you are looking for...
    Add placeholder %Date% : View Idea
    Vote it up.
    Noel

  • Dynamic retrieval in list boxes using JSP

    Dear All,
    I have a list box in a form which is created by extracting data from oracle database. There are approximately 26000 records which are added dynamically in the list box. There are five rows in the form and each row has to have a list box with all records. Now if i retrieve all records for all list boxes, the page takes high time to load. I also tried using String array to read once and write them using loops in list box. But even then the loading time is quiet high. Is there some better way so that the page loads fast enough. I am using Oracle Database and the table is indexed.
    Thanks & Regards,
    Gagan Arora

    Well, it's big enough to make any page slow... but you can try to load all the list boxes in the client side with javascript.
    i make that usually, create a javascript strings array and on the "onLoad" event fill all the list boxes with the values in that array.
    but anyway is too much data.

  • IS there a way to fix the issue with text list boxes where they shift (empty space is smaller than the text size) when two text lsit boxes are side by side?

    Currently I have a webpage I designed for a company where I have multiple text list boxes side by side for the purpose of displaying data in each one based on a category in the database. So a text list box for the primary key, name, serial number, etc. I have to use Firefox as it typically works best for printing and functionality for the page. The single issue we are having is that in Firefox if the field is null as far as text the text are shrinks meaning all the data in that list box shifts up and is no longer in line with its congruent data in the other text list boxes. In other browsers that's not a problem and everything stays lined up regardless of whether there's text in the box or not.
    Unfortunately I cannot provide a link but if contacted I will provide screen shots.

    Try posting at the Web Development / Standards Evangelism forum at MozillaZine. The helpers over there are more knowledgeable about web page development issues with Firefox. <br />
    http://forums.mozillazine.org/viewforum.php?f=25 <br />
    You'll need to register and login to be able to post in that forum.

  • How can we use list box on selection screen

    hi, howe can we use list box on selection screen and how can we populate the dat ainto the list box and how can we retrive data based on list box from ther database.
    thanks in advance
    raju

    Use the VRM_SET_VALUES function module.
    DATA: list              TYPE vrm_values,
          value             LIKE LINE OF list.
               AT SELECTION SCREEN OUTPUT
    AT SELECTION-SCREEN OUTPUT.
      name = 'P_OBJECT'.
      CLEAR list.
      REFRESH list.
      CLEAR value.
      value-key = '1'.
      value-text = 'Development Class'.
      APPEND value TO list.
      CLEAR value.
      value-key = '2'.
      value-text = 'Program'.
      APPEND value TO list.
      CLEAR value.
      value-key = '3'.
      value-text = 'Function Module'.
      APPEND value TO list.
      CLEAR value.
      value-key = '4'.
      value-text = 'Database Table'.
      APPEND value TO list.
      CLEAR value.
      value-key = '5'.
      value-text = 'Structure'.
      APPEND value TO list.
      CLEAR value.
      value-key = '6'.
      value-text = 'View'.
      APPEND value TO list.
      CLEAR value.
      value-key = '7'.
      value-text = 'Data Element'.
      APPEND value TO list.
      CLEAR value.
      value-key = '8'.
      value-text = 'Table Type'.
      APPEND value TO list.
      CLEAR value.
      value-key = '9'.
      value-text = 'Class / Interface'.
      APPEND value TO list.
      CLEAR value.
      value-key = '10'.
      value-text = 'Type Group'.
      APPEND value TO list.
      CLEAR value.
      value-key = '11'.
      value-text = 'Domain'.
      APPEND value TO list.
      CLEAR value.
      value-key = '12'.
      value-text = 'Search Help'.
      APPEND value TO list.
      CLEAR value.
      value-key = '13'.
      value-text = 'Lock Object'.
      APPEND value TO list.
      CALL FUNCTION 'VRM_SET_VALUES'
        EXPORTING
          id              = name
          values          = list
        EXCEPTIONS
          id_illegal_name = 1
          OTHERS          = 2.
      IF sy-subrc <> 0.
        MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      ENDIF.

  • List box in table

    Hi...
    I have a table with 3 list box. Based on selection in one list box another listbox must be populated.
    i have written event for that list box... that event is working fine for first row alone.. if i select second row & get the data from the list box its reading first row only...
    How to specify the index... Since there is no lead selction...
    Any idea or example program...
    Thanks in advance.
    Kalpanashri Rajendran.

    Hello,
    I think you can follow this,
    calling these methods from the respective classes.
    GET_STATIC_ATTRIBUTES from IF_WD_CONTEXT_ELEMENT
    GET_SELECTED_ELEMENTS from IF_WD_CONTEXT_NODE
    You can achieve the required behaviour.
    If you want to specify the index,
    SET_LEAD_SELECTION_INDEX(Set Element of Lead Selection with Index) from interface:IF_WD_CONTEXT_NODE.
    Before setting the index, get the data from node and put it in to internal table.
    Loop at that internal table.
    populate lv-tabix.(sy-tabix)
          CALL METHOD lo_nd_roles_users->set_lead_selection_index
            EXPORTING
              index = lv_tabix.
    endloop.
    This is not exact code but hope will give u some idea....!
    Cheers,
    Bharath

  • How Do I Filter a Report Using a Multi Select List Box and Specifying Date Between Begin Date and End Date

    Hope someone can help.  I have tried to find the best way to do this and can't seem to make sense of anything.  I'm using an Access 2013 Database and I have a report that is based on a query.  I've created a Report Criteria Form.  I
    need the user to be able to select multiple items in a list box and also to enter a Begin Date and End Date.  I then need my report to return only the records that meet all selected criteria.  It works fine with a ComboBox and 1 selection but can't
    get it to work with a List Box so they can select multiple items.  Any help is greatly appreciated while I still have hair left. 

    The query should return all records.
    Let's say you have the following controls on your report criteria form:
    txtStart: text box, formatted as a date.
    txtEnd: text box, formatted as a date.
    lbxMulti: multi-select list box.
    cmdOpenReport: command button used to open the report.
    The text boxes are used to filter the date/time field DateField, and the list box to filter the number field SomeField.
    The report to be opened is rptReport.
    The On Click event procedure for the command button could look like this:
    Private Sub cmdOpenReport_Click()
    Dim strWhere As String
    Dim strIn As String
    Dim varItm As Variant
    On Error GoTo ErrHandler
    If Not IsNull(Me.txtStart) Then
    strWhere = strWhere & " AND [DateField]>=#" & Format(Me.txtStart, "yyyy-mm-dd") & "#"
    End If
    If Not IsNull(Me.txtEnd) Then
    strWhere = strWhere & " AND [DateField]<=#" & Format(Me.txtEnd, "yyyy-mm-dd") & "#"
    End If
    For Each varItm In Me.lbxMulti.ItemsSelected
    strIn = strIn & "," & Me.lbxMulti.ItemData(varItm)
    Next varItm
    If strIn <> "" Then
    ' Remove initial comma
    strIn = Mid(strIn, 2)
    strWhere = strWhere & " AND [SomeField] In (" & strWhere & ")"
    End If
    If strWhere <> "" Then
    ' Remove initial " AND "
    strWhere = Mid(strWhere, 6)
    End If
    DoCmd.OpenReport ReportName:="rptMyReport", View:=acViewPreview, WhereCondition:=strWhere
    Exit Sub
    ErrHandler:
    If Err = 2501 Then
    ' Report cancelled - ignore
    Else
    MsgBox Err.Description, vbExclamation
    End If
    End Sub
    If SomeField is a text field instead of a number field, change the line
            strIn = strIn & "," & Me.lbxMulti.ItemData(varItm)
    to
            strIn = strIn & "," & Chr(34) & Me.lbxMulti.ItemData(varItm) & Chr(34)
    Regards, Hans Vogelaar (http://www.eileenslounge.com)

  • Data in List Box

    I am currently creating a list box on a selection screen.  I have created the box, but I am unable to populate it with data.  After looking through many resources and several threads through this forum I am still unable to populate it.  I have followed syntax posted on this forum and others, yet my list box still remains empty.  I am using the call function 'VRM_SET_VALUES' and doing the proper exports, I have used TYPE-POOL: TRM, and have created the data declaration.  Yet the box remains empty.  Anything I should look for to correct this problem?

    Hi,
    Here is the simple Program
    REPORT ZLIST.
    TYPE-POOLS: VRM.
    DATA: NAME  TYPE VRM_ID,
          LIST  TYPE VRM_VALUES,
          VALUE LIKE LINE OF LIST.
    PARAMETERS: PS_PARM(10) AS LISTBOX VISIBLE LENGTH 10.
    AT SELECTION-SCREEN OUTPUT.
    NAME = 'PS_PARM'.
    VALUE-KEY = '1'.
    VALUE-TEXT = 'LINE 1'.
    APPEND VALUE TO LIST. VALUE-KEY = '2'.
    VALUE-TEXT = 'LINE 2'.
    APPEND VALUE TO LIST.
    CALL FUNCTION 'VRM_SET_VALUES' EXPORTING ID = NAME VALUES = LIST.
    START-OF-SELECTION.
    WRITE: / 'PARAMETER:', PS_PARM.
    Regards
    Sudheer

Maybe you are looking for

  • ThinkPad USB 3.0 Dock Driver Availability Win 8.1

    Driver for ThinkPad USB 3.0 Dock station cannot run under Win 8.1.  Support Center stated: Driver being developed.  Does anyone have an expected completion date? Moderator Note; subject edited.

  • Import process customization

    Hi Sap Experts, Right now i am working in a project where mostly material is import.Can any body tell me,How import process is differnt from local purchase.what access sequence,condition types,control data.and taxes are define in customization menu.H

  • IPhone 6 plus storage usage spikes over 30GB

    I have an iPhone 6 plus 64GB. iOS 8.2. SInce the 8.2 update, my phone has been giving me a notifcation saying that it has low storage. When I look at my usage, I have 5GB of photos, 2 GB of music and various smaller apps under 1 GB. The available sto

  • Hands off my browser window

    How can I prevent web pages from resizing and/or repositioning (hard to decide, which of these is a greater nuisance) my browser window with javascript in Safari 2.0.3? Thanks

  • Writing List Header

    Hi all, Iam using something as follows for writing a list out. I want to write 2 lines of some header details(dynamic text) above the following table output using "write".Is that possible..... LOOP AT itab.   WRITE: /1(1)'|', 2(20) itab-Text1 CENTERE