Get the values of the list that exist in bean

Hello to all the programmers ,
I have a list that i initialize in the action (it's can be also servlet in pure j2ee) , the list is exist in the bean and then i used that list in the jsp page getting it from the bean.
I pass over the list by logic iterate and show each object of the list , till this point it's work fine.
Each of the object in the list has an attribute that used for the radio for selection , the problem is how do i get the selection of the user from the jsp.
My code is here :
The action from (Bean) :
public class userBean extends ActionForm {
     private String firstName = null;
     private String lastName = null;
     private List theList = null;
     public String getFirstName() {
          return firstName;
     public void setFirstName(String firstName) {
          this.firstName = firstName;
     public String getLastName() {
          return lastName;
     public void setLastName(String lastName) {
          this.lastName = lastName;
     public List getTheList() {
          return theList;
     public void setTheList(List theList) {
          this.theList = theList;
}The Object that the list contain :
public class userDetails {
    private String firstName = null;
     private String lastName = null;
     private int selection = 0;
     public userDetails(String firstName, String lastName, int selection) {
          super();
          this.firstName = firstName;
          this.lastName = lastName;
          this.selection = selection;
     public String getFirstName() {
          return firstName;
     public void setFirstName(String firstName) {
          this.firstName = firstName;
     public String getLastName() {
          return lastName;
     public void setLastName(String lastName) {
          this.lastName = lastName;
     public int getSelection() {
          return selection;
     public void setSelection(int selection) {
          this.selection = selection;
}The action that contain the list for the jsp :
public class userAction extends Action{
     @Override
     public ActionForward execute(ActionMapping mapping, ActionForm form,
               HttpServletRequest request, HttpServletResponse response)
               throws Exception {
          ArrayList listNames = new ArrayList ();
          listNames.add(new userDetails("Joe","Pashi",0));
          listNames.add(new userDetails("Moshe","Yaniv",0));
          listNames.add(new userDetails("Bill","Clinton",0));
          listNames.add(new userDetails("Bill","Gatez",0));
          listNames.add(new userDetails("John","Kendi",0));
          ((userBean)form).setTheList(listNames);
          ActionForward forward = mapping.findForward("userDetails");
          return forward;
}The jsp page the present the list of the objects :
<%@ taglib uri="/WEB-INF/struts-bean" prefix="bean" %>
<%@ taglib uri="/WEB-INF/struts-logic" prefix="logic" %>
<%@ taglib uri="/WEB-INF/struts-nested" prefix="nested" %>
<%@ taglib uri="/WEB-INF/struts-tiles" prefix="tiles" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html"%>
<html:html>
<html:base/>
<body>
   <html:form action="/userAction.do">
             <html:text property="firstName"></html:text>
             <html:text property="lastName"></html:text><br/>
             <html:submit value="Click Here"></html:submit>
             <br/>
             <logic:iterate id="userDetails" name="userBean" property="theList" >
                <html:radio name="userDetails" property="selection" value="1"></html:radio>
                <bean:write name="userDetails" property="firstName" />
                <html:hidden property="firstName" value="${userDetails.firstName}"/>
                <bean:write name="userDetails" property="lastName"/>
                <br/>
             </logic:iterate>
   </html:form>
</body>
</html:html>so the big question is how do i get the selection of the user from the bean.
Thanks in advance

Hi ,
thanks for asking me.
I will explain that again i have a list of names that i set by the action and then pass it to the jsp.
In the jsp page i show the list of the names and near each name there is a radio button , i want the user select any name from the list to get it from the bean , How do i do that ?
thanks

Similar Messages

  • How to get the list of values for a dynamic parameter using Web Services SDK?

    <p>I am struggling to get the list of values for a dynamic parameter of a report.</p><p>I am using Java Web Services SDK ... I tried to use PromptInfo.getLOV().getValues() method but it does not work.</p><p>First of all ... is this possible (to get the list of values for a dynamic param) using Web Services?</p><p>Second of all, if this is possible, how should I do it ... it seems it works fine when running the report from CMC. It asks for DB logon info and after that it provides a list of values.</p><p>Thx </p>

    <p>Your assumption is correct. We are trying to get the LOVs from the Crystal Report. I was not aware that this is not supported by Web Services SDK.</p><p>We used Web Services SDK to integrated the Crystal Reports in our web application. We implemented some basic actions for reports: schedule, view instances, run ad-hoc reports.</p><p>We encountered this problem when trying to run/schedule reports with dynamic parameters (a list of values from DB). We were unable to get the LOVs.</p><p>Please let me know if you can think of an alternative to look at.</p><p>Thanks a lot,</p><p>Catalin </p>

  • HT5616 I have an apple id; but when I try to sign in to iCloud, I get the msg that the apple id is not an iCloud account.  However, apple was able to bill me for my non-existent iCloud account.  How does that happen?

    I have an apple id; but when I try to sign in to iCloud, I get the msg that the apple id is not an iCloud account.  However, apple was able to bill me for my non-existent iCloud account.  How does that happen?

    If you didn't create an iCloud account on an iOS device or Mac, you don't have one.  You can't create an account on a PC.  If you were charged for an iCloud storage upgrade without having an account, contact the Apple online store at the bottom of this page for a refund.

  • How to get the list of object that are going to modify during the upgrade?

    We are upgrading sap 4.OB to ECC 6, is there any place we will get the list of standard object which are going to modify in service market place? Please let me know the link to get those details.
    Thanks

    Usually you get this list when upgrading first system (sandbox type) via SPDD and SPAU. (useful for objects modified in your system - SNOTE or mofications) - The whole list of modified objects will be huge,  many (most) objects were modified (created, even deleted) those last 13 years.
    There are also tools that may help you like [panaya|http://www.panayainc.com/] (but i'm not sure for a 4.0B, it worked fine for a 46c) - look for tools/vendor at [Partner Information Center: Search|http://www.sap.com/partners/directories/SearchSolution.epx]
    Regards,
    Raymond

  • HT4915 How to I completely delete my music in iCoud so I can start over with new play lists? I get the message that my files aren't  music files. Can I see what is in my iCloud file?

    How to I completely delete my music in iCoud so I can start over with new play lists? I get the message that my files aren't music files. Can I see what is in my iCloud file?

    Thank you Csound1, ok I guess I did manage to delete it but now when I copy new mp3 files they come as mpeg and iCoud won't accept them? Why? Do I have to convert them all now or can I set it somewhere to take them as mp3's. Appreciate the help. Have a great day! Cheers Steve

  • When trying to reinstall InDesign 5.5, I get the message that my serial number is invalid. It is the same one listed on the Adobe site. Why can't it be recognized?

    When reinstalling InDesign 5.5 I get the message that I have an invalid serial number, yet it is the same one listed in my account on the Adobe page. I have already uninstalled the current version, so this is quite disconcerting.

    Error "The serial number is not valid for this product" | Creative Suite
    http://helpx.adobe.com/creative-suite/kb/error-serial-number-valid-product.html

  • Trying to use Web LCID property to get the List name in client object Model

    Hi ,
    I am trying to change the "Personal Documents" list NoCrawl property under MySite using SharePoint Client Object Model. As we use  web.Lists.GetByTitle("Personal
    Documents"); method to get the list,but here problem is :for different language List name is in their language.So I tried to use LCID property of the WEB and
    have taken key-value pair (PersonalSiteOnet_List_PersonalDocuments) from the resource file for that language from 14 hive.
    Example:I have selected Spanish language .there are so many LCID for Spanish language but Microsoft has given only one language pack for Spanish.
    Then,My Question is that
    "All LCID for Spanish language are using same Spanish language pack dictionary file OR something else"
     

    Hi,
    According to your post, my understanding is that your requirement is getting list in different language.
    Here are two ways for your reference:
    1. We can use getById method instead, so that we can avoid the language issue.
    2. We can use an array to store the different list name in different language in you JavaScript code, then use the code snippet below to get the list:
    var userLcid =_spPageContextInfo.currentLanguage;
    var localizedStrings = {
    ListName: {
    _1033: "EnglishName",
    _3082: "SpanishName"
    var listName=localizedStrings.ListName["_" + userLcid];
    var list=web.Lists.getByTitle(listName);
    More information:
    http://msdn.microsoft.com/en-us/library/hh670609.aspx
    http://wellytonian.com/2012/11/language-packs-sharepoint-2010/
    Best Regards
    Dennis Guo
    TechNet Community Support

  • How to get the list of IDM users in a workflow.

    Hi,
    I wanted to get the list of IDM users in a workflow into a list.Now I tried to use getObjects Method,I do not have the display session here,I passed the workflow context or WF_Context.But it is giving exception like context null .
    I used the same method in a form and it worked.How can I get the list of users in a workflow.It is for customizing reports.
    Thanks and Regards,
    Pandu
    Any Idea on how to customize reports including attributes from resources and auditing attributes etc.Any help would be really great.
    Thank you.

    Hi John,
    I get this exception WorkItemForm: no id.
    This comes when I click on the other column.I generate the data needed in a report and display it as a sorting table when I get the data.
    I want to give the user ability to sort data by different columns.But when I click any column I get the exception
    WorkItemForm: no id
    How can I save a workitem on a manual form before invoking it from a manual action.
    Here is the code snippet
    <Field name='tblUsers'>
            <Display class='SortingTable'>
              <Property name='selectEnable' value='false'/>
              <Property name='align' value='left'/>
              <Property name='linkEnable' value='false'/>
              <Property name='sortEnable' value='true'/>
              <Property name='width' value='400'/>
              <Property name='columns'>
                <List>
                  <String>Account id</String>
                  <String>First Name</String>                      
                </List>
              </Property>
            </Display>      
            <FieldLoop for='row' in='_searchList[*]'>
              <Field name='enduserId'>
                <Display class='Label'>
                  <Property name='value'>
                    <block trace='true'>
                      <invoke name='getAccountId'>
                        <ref>row</ref>
                      </invoke>
                    </block>
                  </Property>
                </Display>
              </Field>
              <Field name='lblfirstname'>
                <Display class='Label'>
                  <Property name='value'>
                    <invoke name='getAttribute'>
                      <ref>row</ref>
                      <s>firstname</s>
                    </invoke>
                  </Property>
                </Display>
              </Field>
         <FieldLoop>      I think I may need to save some workItem,That is why this may be giving the error.How can I correct this.
    Thanks,
    pandu

  • How to get the list of batch jobs running in a specific application server

    Hi Team,
    I am trying to check in SM37 if there is any specific condition to get the list of batch jobs assigned to a specific target server but cant find any.
    Is there is way to find the list of batch jobs assigned to run in one specific application server.( Target server specified in SM36 while job creation)

    Hello,
    This is what you can do in SM37.
    Execute the list of batch jobs, when the result appears on the screen edit the ALV grid via CTRL+F7.
    Now add the following columns "TargetServ" and "Executing server".
    You will now have two extra columns in your result list.
    TargetServr contains the value of the application server where the job should run when you have explicitely filled it in.
    Often this is empty, this means that at runtime SAP will determine itself on which application server the job will run (depending of course where the BGD processes are defined).
    Executing server is filled in always for all executed jobs, this is the actual application server where the job has run.
    You can also add these two fields in your initial selection screen of SM37 by using the "Extended job selection" button.
    I hope this isusefull.
    Wim

  • Need to get the list of all procedures called in an object

    Hi,
    I am trying to find the list of all proceudres called in an object. I can get the list of packages and individual procedures/functions using dba_dependencies, all_dependencies or user_dependencies. However this would not give me the list of procedures of a package that are used in my object.
    How to find the procedures of a package (and not just the package name) being called in another object?
    Thanks in advance
    Upendra

    You can take the package name from user_depencies and query the USER_SOURCE table for the object name where the package name exists.
    Eg code, here PKemp is the package name.
    SELECT SUBSTR(TEXT,INSTR(TEXT,'PKEMP'))
    FROM USER_SOURCE
    WHERE NAME = 'PROCEMP'
    AND INSTR(TEXT,'PKEMP') >=1
    SUBSTR(TEXT,INSTR(TEXT,'PKEMP'))
    PKEMP.SALUP;

  • How to get the list of archeived documents

    Dear Experts,
    How we can get the list of archeived documents ? Infact I am not able to some documents,which are already generated as per the number range interval FBN1.I am not able see these documents in parking/held document lists as well.
    Regards
    Partha
    Edited by: Partha_Mumbai on Feb 24, 2010 2:39 PM

    Hi
    Displaying the Archived List
    To display the archived list, proceed as follows:
           1.      In the SAP System initial screen, choose Office -> Business documents ->Lists.
           2.      Enter the appropriate search information on the selection screen (in our example, the name of the report).
           3.      Choose Execute. The system displays all the of archived lists that meet your selection criteria.
           4.      Select a list and choose, for example, Display from archive system. The system displays the archived list.
           5.      If the list contains index lines, you can search for them using Edit -> Search by attribute. In this example, the list contains an index line every 100 lines, with the following entries:
    Name
    Value
    Index
    IDX
    Number
    Sequence number of index lines
    You can use the Search by attribute function to navigate to line 100, 200, 300, and so on. The index lines themselves are not displayed. You can only use Search by attribute if the list was sent to the spool system while the program was running. Search by attribute is not available if the list was displayed first, then archived afterwards.
    Regards,
    ramanuja chary

  • I can't open iTunes on my brand new Mac!I am getting the message that I am exceeding my limit of 5 computers! Huh, I only have two desktops and two laptops (not counting my new MacBook Pro). I do have an old (discarded) laptop that had iTunes! Help!!

    Hi! I have a new MacBook Pro, but I haven't been able to put iTunes on it even though I have used it for years on my iPhone, iPad, and two Windows desktops and two Windows laptops. I keep getting the message that "I am exceeding my iTunes account limit of 5 computers (not counting my iPhone and iPad, which are explicitly excluded from the count according to the message)". As anyone can see, I only have 4 computers, so I should not have any problems with installing iTunes, but this same message says that I need to deauthorize at least one computer or maybe I have extra authorizations on a computer.
    I can't even find a list or map of the computers on my iTunes account! Please, somebody help ASAP!!!!! Thanks!!!!!
    Murray in Atlanta
    **** cell
    Message was edited by: lmfj20001
    <Personal Information Edited By Host>

        Deauthorize all of your computers and authorize the computers you use.
        http://support.apple.com/en-us/HT6283
      A new Mac comes with 90 days of free tech support from AppleCare.
      AppleCare: 1-800-275-2273
    Best.

  • I'm running Firefox 3.6.23. I get the message that HP Smart Web Printing is not compatible.

    I'm running Firefox 3.6.23 under Windows 7 64 bit. I want to use the HP Smart Web Printing program but under the add-ons I get the message that it is not compatible with this version. What ver. should I be running for compatibility? I saw at one time the icon on the toolbar but it went away after the next reboot. Help.
    Ray
    This question was solved.
    View Solution.

    It is listed as compatible with Internet Explorer versions 6, 7, and 8 .
    Best regards,
    erico
    ****Please click on Accept As Solution if a suggestion solves your problem. It helps others facing the same problem to find a solution easily****
    2015 Microsoft MVP - Windows Experience Consumer

  • In the topmost Firefox menu with File,Edit,View,History,Bookmarks, I can not get the list of bookmarks to display as they did before. The Bookmarks menu does not open up into the list of bookmarks.

    I am running Mac os 10.6.8 and Firefox 6.0.1 on a MacBook Pro and on a desktop Macintosh.
    The large computer displays a list of bookmarks when you click on the uppermost Bookmarks menu.
    The MacBook Pro displays the following when you click on the Bookmarks word in the top menu:
    "Show all Bookmarks, Bookmark this Page, Bookmark all Tabs and an icon with a blue dot next to Bookmarks Toolbar with an arrow to the right and below that it says Unsorted Bookmarks.
    There is no display of the list of bookmarks from which I can chose as I do on the larger desktop macintosh computer.
    How can I get the list of bookmarks to show as a list when I click the Bookmarks menu?

    A possible cause is a problem with the file places.sqlite that stores the bookmarks and the history.
    *http://kb.mozillazine.org/Bookmarks_history_and_toolbar_buttons_not_working_-_Firefox
    You can also try to move (delete) the Firefox plist file.<br />
    See [http://www.macfixit.com/article.php?story=20060606082246983 How .plist files become corrupt and troubleshooting the results]
    Go to "Library > Preferences" and remove the plist file for Firefox (org.mozilla.firefox.plist).

  • Some of my songs in iTunes show up but they won't play. I get the message that my computer isn't authorized to play them when I only have one computer.

    I recently did the update for iTunes and after I did that I got the error message: MSVCR80.dll file not found.  I followed the suggestions from someone in this community to fix it and now some of my songs aren't playing.  And they are the ones that I purchased from iTunes not CDs that I have and ripped to my iTunes library. I can see the songs listed in my iTunes library as well as on my iPod but yet they won't play.  On my computer I get the message that this computer is unauthorized to play them and to authorize it.  I only have one computer, so I have no idea why I'm getting this message.  And does anyone have any suggestions as to how to get all of the iTunes songs to play again?

    Hello Angel82co,
    It sounds like you have some songs in your library that are not playing, and when you try to play them you are being told the computer is not authorized to play them. I would start by verifying that your computer is still authorized, and take note of the Apple ID that you sign in with:
    To authorize a computer, follow these steps:
    Open iTunes.
    Choose Store > Authorize This Computer from the menu bar.
    You may need to show the menu bar to see this option in Windows. In earlier versions of iTunes, you can access this option from the Advanced menu.
    Enter your Apple ID and click Authorize.
    If your Apple ID uses an expired MobileMe account, you can still authorize your computer.
    From: iTunes Store: Authorize or deauthorize your Mac or PC
              http://support.apple.com/kb/ht1420
    If the issue persists, next I would use the following article to double check that these songs were purchased under the same Apple ID you used to authorize the computer:
    Recovering a forgotten iTunes Store account name
    http://support.apple.com/kb/ht1920
    Open iTunes
    Highlight one of the items you have purchased (You can find your purchases in your Purchases playlist).
    Choose File > Get Info.
    Click the Summary tab.
    The Account Name area will list the account used to purchase the item. Unless you have changed accounts, this is your iTunes Store account name.
    If it is the same Apple ID then I would next delete the song, and re download it from your purchased history, with this article named:
    iTunes 11 for Windows: Download previous purchases from the iTunes Store
    http://support.apple.com/kb/PH12491
    Thank you for using Apple Support Communities.
    All the best,
    Sterling

Maybe you are looking for

  • Printing Problem on IE10

    I'm using Visual Studio 2010 with Crystal Report for VS 13_0_13 on Windows 7.  I create a bunch  of Crystal Report but when I try to print them nothing happen.  The Print Dialog screen also weird, non of the boxes has any setting and there are no pre

  • Computer will not boot up.  I have tried running disk utility and re-installing OSX.  It says disk locked

    I am new to Macs and have bought a 13" Macbook Pro and a IMac 21.5" 14 months ago.  I have only used the Macbook pro about 15-20 times and after upgrading to Maverick it will not boot up.  I get the white screen and a spinning circle.  I have tried D

  • Late 2007 macbook slowing down

    My late 2007 2.2 macbook has slowed considerably for the first time in its 3+ years with me. Suggestions on what to check for that might be causing it are welcome. Thanks, Jose PS. Running Snow Leopard (up to date), 4GB Ram, 320GB 5,400rpm

  • Ipod will not show in windows explorer

    i only have had this problem since i upgraded the software on my ipod, and now i wished i hadnt. the ipod displays fine in itunes, but only shows up in windows explorer while it is charging or being updated (for very limited amount of time). i use my

  • Removing Image Link Borders

    Hello there, I've been playing aroudn with CSS in Dreamweaver CS3 and try and rid the border around linked images/graphics. I've tried using border: 0; but this doesn't seem to be doing the job. The code I have used is as follows: