In that case I did try this code, but I am getting. Its not printing the output at all. But when I compile and run the try/catch block code in a seperate
java file, it is printing the contents to the console.
out.println("<html>");
out.println("<body>");
:
:
try
{
String parent = null;
File file = new File(parent, "con1.txt");
FileReader fileReader = new FileReader(file);
BufferedReader buffReader = new BufferedReader(fileReader);
String buffer = new String();
while( (buffer = buffReader.readLine() ) != null)
System.out.println(buffer);
buffReader.close();
}
catch(IOException e)
{
}
:
:
out.println("</body>");
out.println("</html>");
Please tell me how should I direct the ouput the browser.
Thanks
Contents of con.txt is
<table cellpadding="2" cellspacing="0" align="center" width="750" border="1">
<tr align="center"><TD><STRONG><FONT size="2">ID</FONT></STRONG></TD>
<TD><STRONG><FONT size="2">SKU_Number</FONT></STRONG></TD>
:
:
: