cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

how can i solve exception :Neither BindingResult nor plain target object for bean name 'saveCartForm' available as request attribute ?

101012E11
Explorer

Accepted Solutions (0)

Answers (1)

Answers (1)

former_member645475
Discoverer
0 Kudos

Hi ,

Just add model.addAttribute("saveCartForm" , new SaveCartForm()); in your Controller file .

Thanks

101012E11
Explorer
0 Kudos

i want to use this form for all pages then how can I use this

former_member645475
Discoverer
0 Kudos

then you have to put this line in every Controller files

rohit31_raj92
Active Participant
0 Kudos

Then you can bind your form in any handlers or abstract page controller of your project code

That should help you to bind it on all form

101012E11
Explorer
0 Kudos

ok thanks.

101012E11
Explorer
0 Kudos

In abstract controller how and where to bind it?

rohit31_raj92
Active Participant
0 Kudos

Same like which @prasanth kola explains using model add attribute

for example : like metatags are send as model add attribute .