• 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
  • Liutauras Vilda
  • Paul Clapham
Sheriffs:
  • paul wheaton
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Piet Souris
Bartenders:
  • Mike London

sending map object to success view

 
Ranch Hand
Posts: 115
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all ,

am using simple form controller and in controller i need to send a map object to success view. The view has to display all the elements of the map object in the form check boxes . please tell me how to do this ?

 
indu iyengar
Ranch Hand
Posts: 115
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
my code in controller is :

code in success page is :

but ends up with the exception :

please help me how to get both keyvalue and value . any help would be highly appreciated..
 
Rancher
Posts: 377
Android Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hey,

Your error seems to be about page directives? Can you show us what page directives you have on your JSP?

Sean
 
indu iyengar
Ranch Hand
Posts: 115
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
thanks for your reply.. am not using any page directive in jsp. But in spring config file am mentioning it as session form="true"...

in none of forms and views am using any directives, but able to get messages. Even here am getting the size of the map, but not values..

is this essential to use directives in jsp while using map ? please clarify , how can I get the values in successview ?
 
Ranch Hand
Posts: 672
4
Eclipse IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Indu,
you are able to get the size of the map, then, are you able to go inside the forEach loop? Also, what does just ${map} print in your jsp? Also, which is the 4th line in JSP, where the Exception is coming?
 
indu iyengar
Ranch Hand
Posts: 115
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi guys I solved that .. thanks for replying ...
actually the problem is i have not added the code in the jsp ..
 
reply
    Bookmark Topic Watch Topic
  • New Topic