Win a copy of Secure Financial Transactions with Ansible, Terraform, and OpenSCAP this week in the Cloud/Virtualization forum!
  • 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
  • Ron McLeod
  • Paul Clapham
  • Jeanne Boyarsky
  • Bear Bibeault
Sheriffs:
  • Rob Spoor
  • Henry Wong
  • Liutauras Vilda
Saloon Keepers:
  • Tim Moores
  • Carey Brown
  • Stephan van Hulst
  • Tim Holloway
  • Piet Souris
Bartenders:
  • Frits Walraven
  • Himai Minh
  • Jj Roberts

javax.el.PropertyNotFoundException: Property 'codigoproduto' not found

 
Ranch Hand
Posts: 302
3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi, I have a getter and setter class but when I call this bean in my JSP to load records of MySql table to jtable I'm get an error that say that a item of my bean class not found, I can not see  where are this error.
My bean:

Log of error:

Thanks in advance.
 
Rancher
Posts: 4801
50
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
First off the naming for your instance variables should be camel case, so codigoProduto and not CodigoProduto.
You method names are correct, but the reference to the instance variables in your el needs to match the variable name...it is case sensitive.
So codigoProduto and not codigoproduto .
Same goes for descricaoproduto.

Technically speaking the instance variable could be called anything, as it's the getter that the el engine targets, but it helps to get the naming correct.
 
Cezar Apulchro
Ranch Hand
Posts: 302
3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Problem still the same, now in 'descricaoproduto'.
Log error:
 
Cezar Apulchro
Ranch Hand
Posts: 302
3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi, problem is solved. I have created a new bean with string codigo, descricao, quantidade e preco, then alt+insert and generated the getter, setter and tostring. What I can't understan is why in the first post codigoproduto works fine and descricaoproduto don't work.
Thanks for all.
 
Listen. That's my theme music. That's how I know I'm a super hero. That, and this tiny ad told me:
SKIP - a book about connecting industrious people with elderly land owners
https://coderanch.com/t/skip-book
reply
    Bookmark Topic Watch Topic
  • New Topic