• Post Reply Bookmark Topic Watch Topic
  • New Topic

code to search a string in a log file.  RSS feed

 
vellan vaz
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Can any one give me the code to search a string in a log file.

Thanks in advance

vellan
 
Sandeep Kumar Jakkaraju
Ranch Hand
Posts: 75
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You can read the file line by line and look for the required string ........
You can use classes like DataOutputStream and StringTokenozer to achieve your goal ....
 
Petrus Pelser
Ranch Hand
Posts: 132
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
vellan vaz wrote:
Can any one give me the code to search a string in a log file.


No.

But we will help if you show some initiative.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!