• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Get values from a checkbox list

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi ppl, I need some help.


I have a page showing a list of movies previously inserted by the user and I want to make an action for removing the movies from the arraylist in which they are.



My mostraElenco.jsp is




My struts-config is




And my RemoveMovieAction.java is



ListaFilm is made like this



what i get when i try to access to mostraElenco.jsp is




I know i shouldn't do this



since ListaFilm is static, I tried to do
ArrayList<Movie> filmDaRimuovere = (ArrayList<Movie>) form;
but I get errors since the compiler tells me that it can't convert from ActionForm form to ArrayList



Someone can help me?
 
Ranch Hand
Posts: 213
Eclipse IDE Tomcat Server Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
1) The message error is obvious. It cannot find the getter for "listMovie". I don't even see where you have "listMovie" defined. Is it defined and made public in "ShowElencoAction"?
2) You don't do an array of forms. You need to do an array of "Movie".
 
reply
    Bookmark Topic Watch Topic
  • New Topic