Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Bean property isn't setting

 
Charessa Reilly
Ranch Hand
Posts: 39
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
(it's almost been a week! Did you miss me?)

so my jsp uses this code:


the setter in the InquireRecord class:


the output:
the value is:


I'm not getting any errors anywhere. it's just not setting that property. Any ideas? (in other words, what typo and major misconception do I have this time?)
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64827
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A few things:
  • The setProperty action is quaint. You already know about <c:set>, why use setProperty at all?
  • Does a bean of that name already exist? The content of the useBean only executes when a new bean is created.
  •  
    Charessa Reilly
    Ranch Hand
    Posts: 39
    • Mark post as helpful
    • send pies
    • Quote
    • Report post to moderator
    I... hadn't realized I could use c:set. I thought it was just for jsp variables, not bean interaction.

    but after a little research, I tried that and it worked

    Thanks!

    (no, there weren't any other beans with that name)
     
    Consider Paul's rocket mass heater.
    • Post Reply
    • Bookmark Topic Watch Topic
    • New Topic