• Post Reply Bookmark Topic Watch Topic
  • New Topic

javalangnullpointerexception.

 
bobby reddy
Greenhorn
Posts: 27
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello everyone,
my jsp program displays the error message: "java.lang.nullpointerexception".
could any one tell me know how to solve this error message and also how can we know to which field on the jsp this error message is reffering to?

Thanks,
bobby.
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 65520
105
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This means that a reference in your code is null when you tried to use it.

Without further details, it's impossible to say any more.

Please read this.
 
bobby reddy
Greenhorn
Posts: 27
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
for example: if i have three fields- f1,f2 and f3.
how can we know for which field the code is null and i am using it.

bobby
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 65520
105
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I could have nothing at all to do with your fields. You should start by posting the stack trace from the error.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!