Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

servlet context listener problem

 
sandeep pant
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi


_______________________________________________________________________________________________
i am trying to read content from a text file
but it is giving this error


java.lang.NullPointerException
at Check.check.doPost(check.java:92)


content of leagues.txt file is

1 sandeep summer
 
Goutam Chowdhury
Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi,
Check your Check.java...if possible then paste it here also

Thanks
 
Deepakkumar Devarajan
Ranch Hand
Posts: 54
Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You are trying to use an object that has not been initialized with any reference, please check that.
 
sandeep pant
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Deepakkumar Devarajan wrote:You are trying to use an object that has not been initialized with any reference, please check that.

thank you for your help
i have sorted this problem
String[] fields =record.split("\t");

used " " instead of "\t" and it worked
 
Deepakkumar Devarajan
Ranch Hand
Posts: 54
Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
sandeep pant wrote:
i have sorted this problem
String[] fields =record.split("\t");

used " " instead of "\t" and it worked


Thanks for information.
 
sargam dhamija
Greenhorn
Posts: 1
Java Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi i am still running this program but getting null while trying to insert the year season and title values
even I set the empty file"leagues.txt" to database using function open as by right click on it, Now its showing it as database...please let me know a solution..
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic