This week's book giveaway is in the Mac OS forum.
We're giving away four copies of a choice of "Take Control of Upgrading to Yosemite" or "Take Control of Automating Your Mac" and have Joe Kissell on-line!
See this thread for details.
The moose likes Spring and the fly likes sending map object to success view Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Frameworks » Spring
Bookmark "sending map object to success view " Watch "sending map object to success view " New topic
Author

sending map object to success view

indu iyengar
Ranch Hand

Joined: Jul 30, 2010
Posts: 115
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 ?


thanks ,
Indu
indu iyengar
Ranch Hand

Joined: Jul 30, 2010
Posts: 115
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..
Sean Clark
Rancher

Joined: Jul 15, 2009
Posts: 377

Hey,

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

Sean


I love this place!
indu iyengar
Ranch Hand

Joined: Jul 30, 2010
Posts: 115
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 ?
Prasad Krishnegowda
Ranch Hand

Joined: Apr 25, 2010
Posts: 532

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

Joined: Jul 30, 2010
Posts: 115
Hi guys I solved that .. thanks for replying ...
actually the problem is i have not added the code in the jsp ..
 
GeeCON Prague 2014
 
subject: sending map object to success view