title: question is how to export a report made by jasperreport and compiled in jsp page exported as well in a particular section of a jsp page
body: <p>when i am compiling a jrxml file created using ireport and exporting it how to export this page in a particular section of a jsp page
        I searched a lot in google i am not gettting any solutions related to my requirements</p>
  
  <p>if i am writing something in the jsp page nothing is showing only the report getting visible</p>
  
  <p>my code in jsp page is:--</p>
  
  <pre><code>&lt;%@ page language="java" import="net.sf.jasperreports.engine.*" %&gt;
  &lt;%@ page language="java" import="net.sf.jasperreports.engine.export.*" %&gt;
  &lt;%@ page import="java.sql.*,java.io.*" %&gt;
  
  &lt;%
  String filename = request.getParameter("filename");
  String reporttype = request.getParameter("reporttype");
  System.out.println(filename);
  System.out.println(reporttype);
  Class.forName("com.mysql.jdbc.Driver");
  Connection con = DriverManager.getConnection("jdbc:mysql://localhost:3306/kms","root", "root");
  System.out.println("Connection Established");
  
  String path = application.getRealPath("/");
  System.out.println(path);
  JasperPrint jasperPrint = JasperFillManager.fillReport(path + "/reports/" + filename, null, con);
  
  
  System.out.println("Report Created...");
  
  OutputStream ouputStream = response.getOutputStream();
  JRExporter exporter = null;
  
  if( "pdf".equalsIgnoreCase(reporttype) )
  {
  response.setContentType("application/pdf");
  response.setHeader("Content-Disposition", "inline; filename=\"file.pdf\"");
  
  exporter = new JRPdfExporter();
  exporter.setParameter(JRExporterParameter.JASPER_PRINT, jasperPrint);
  exporter.setParameter(JRExporterParameter.OUTPUT_STREAM, ouputStream);
  }
  
  try
  {
  exporter.exportReport();
  }
  catch (JRException e)
  {
  throw new ServletException(e);
  }
  finally
  {
  if (ouputStream != null)
  {
  try
  {
  ouputStream.close();
  }
  catch (IOException ex)
  {
      System.out.println("exception thrown");
  }
  }
  }
  %&gt;
  </code></pre>