Problem to print report with graph

Hello,
I make a vi to print or save in html file my front panel results. In the results, I have a graph and to save it in my report I use the "Append Control Image to Report.vi".
The problem is when I print the report the Image is in the top of page and it's size is limited by the size of the left header text. And the top text (not header but just the Title text) is placed after the image.
Now when I save it in the HTML file, I have any problems in the structure of my report.
If you have suggestions, I listen to.
I have an idea to divert the problem is to make a vi to print the HTML file but I don't know to make it.
Thanks for help.
I have attach the file. A man please print the report and say me if the struct
ure is good. Like this, I know that the problem is a problem to my computer config or print config.(Use Labview 6.1)
Thanks for help.
SAM
Attachments:
Report_generation.zip ‏34 KB

Hi midtisam,
I've run your VI to test it for you. I believe I am seeing the same bahavior that you are. The graph always shows up at the top of the page even though it is added after the header. Also, I tried creating an HTML file and it worked correctly. I would suggest doing this since it seems to work better.
Now, you can not use the Print Report VI with HTML reports. If you are able, I would suggest just creating the HTML report and either printing it from your computer through Internet Explorer or sending the file to whoever needs it. Best of luck.
J.R. Allen

Similar Messages

  • Email reports with graphs as HTML (via schedule)

    == W2K machine with Oracle Reports Server 6i R2 ==
    How can I schedule/design a report if sent via email (in HTML format), so the graph that is part of the reports shows up? Currently, the gif is missing. I can use the "hyperlink" in the web setting to point to the file on the web server, but this means my "customers" need to click the missing object.
    If I send the report as PDF, all is well but again, my customers need to "open" the file.
    Is there a way to email reports with graphs as HTML?
    In any other format where the receiver does not have to take any other action?
    Thx
    Josh

    My bursting SQL query:
    SELECT DISTINCT
    ip.APPL_ID KEY,
    '11F_Search_Prospect_Email' TEMPLATE,
    'RTF' template_format,
    'en-US' locale,
    'HTML' output_format,
    'EMAIL' DEL_CHANNEL,
    ip.email PARAMETER1,
    '[email protected]' PARAMETER3,
    'Welcome' PARAMETER4,
    'true' PARAMETER6
    FROM ugrad.inquiry_prospect ip,
    ugrad.correspondence f,
    ugrad.address e,
    ugrad.f_lookup fl
    WHERE ip.appl_id = f.appl_id
    AND ip.APPL_ID = e.APPL_ID
    AND fl.TYPE_CODE='C'
    AND ip.record_stage = 'Prospect'
    AND e.COUNTRY_CODE=fl.code
    AND e.table_name = 'INQUIRY_PROSPECT'
    AND e.address_type =
    NVL ((SELECT gg.address_type
    FROM ugradadm.address gg
    WHERE gg.address_type =
    DECODE (f.mailpref,
    'Home', 'HOME',
    'Best', 'LOCAL',
    'HOME'
    AND gg.table_name = 'INQUIRY_PROSPECT'
    AND gg.APPL_ID = ip.appl_id
    AND((gg.address_type='LOCAL' AND NVL(gg.address_expir_date,sysdate)>sysdate)
    OR gg.address_type='HOME')),
    'HOME'
    AND f.batchid = :Batch_ID
    This report when bursted sends an email with the layout template as html body.
    The EMAIL configuration is set with a server Port number and its host address.

  • Problem after run report with spreadsheet

    hi evry one
    ther an a problem after run report with spreadsheet .
    after runing iexplorar open and close fast no thing else
    when i check the job from appserver job success with spreadsheet dis format.
    what shall i do.
    thanks.

    Hello,
    Do you use the Oracle Forms builtin WEB.SHOW_DOCUMENT ?
    If yes , take a look to : "IE7 windows opened and closed immediatly"
    http://www.experts-exchange.com/Software/Internet_Email/Web_Browsers/Internet_Explorer/Q_23304982.html
    You can test the solution suggested :
    We have found the setting that we needed, under the Internet Options
    Security tab, if you select the internet zone, and click the custom level
    button, then scroll down to the Downloads section, the first option is
    Automatic prompting for file downloads, setting this to enable keeps IE 7
    from interfering with this sort of download.
    Regards
    Example with screen shots :
    http://www.celt.iastate.edu/webct/securitysettings.html
    Regards

  • Hyperion Anaylzer - how to Print report with information in pages?

    Hi,<BR><BR>I use Hyperion Analyzer Version: 6.1.1.00206 (from Help | About menu).<BR><BR>I created report with pages (on Navigate button selected the Pages). In pages are months (January, February, March, etc).<BR><BR>Now I would like to print current report. So I did:<BR>1. click on arrow beside Print button<BR>2. Print Current Report windows is displayed. I selected default options and press OK button.<BR><BR>Report is printed, but there is no page information printed out. So on paper there is report without months (January, February, March, etc).<BR><BR>How to print report with information in pages?<BR><BR>Thanks,<BR>Grofaty

    Jia Shun,
    I had the same issue for printing A/R Invoices - I created a Crystal Report based on a SQL View, works fine with A/R Invoice document, but the Draft Invoice printing has 3 pages: 1st page blank, 2nd page with watermark "DRAFT", 3rd page my Crystal Report layout without any data. When printing normally it is only 1 page.
    Here is what I did as a work around:
    Create two SQL Views, one select from OINV (joining INV1 and other tables needed), the other select from ODRF (joining DRF1 and other tables needed), for the draft printing.
    Create two identicle Crystal Reports, only difference are: datasource location (from different views), the "draft" crystal report has a watermark section.
    Go to Administration>System Initialization>Print Preferences and uncheck "Print draft watermark..."
    Import both crystal reports. Invoice can be printed normally. But the Draft Invoice has more steps: Open Draft document report, change settings so it shows the DocEntry in the Draft Table. Select and open the desired document, hit Print Preview, and enter the DocEntry, it displays the layout with data and "DRAFT" watermark.
    This is a workaround. I don't like it because it is not scalable - too much workload if you want to print 100 invoices.
    Hopefully someone will provide a better solution.
    regards,
    G

  • Problem scheduling webi reports with XI3.1 pending forever

    Hello,
    I've got a problem scheduling webi reports with XI3.1 scheduler.
    After confiming scheduling job (loggin in with "administrator" user), status remains "pending" forever(using Infoview or CMC).
    I tried different job recurrence a modalities (attachment formats, destination user etc).
    I also try to add (-javaArgs "Xmx900m,Xincgc,server") wich is the SAP solution found on its portal but it does not work.
    I use BO XI 3.1 in Windows 2003 server, after the install I reduced the maximum memory of Java in the tomcat 5.5.2 server from 1024 to 512 because the server never started with the initial size.
    Please I need Help.
    thanks in advance,
    Samy

    Hi,
    Below SAP solution found found in BOB Forum.
    I applied this solution and now everything works fine !!
    I just add  this -javaArgs "Xmx900m,Xincgc,server"  in the command line of the server
    Hope this helps:
    Symptom
    Scheduled WebIntelligence reports remain stuck in 'pending' status after installing Microsoft windows patches of April 2009. Restarting the Adaptive Job Server, Central Management Server or Server Intelligence Agent has no effect.
    The Event Viewer logs show the following entry: Unable to start the sub-process (Job Server Child). Cause : Couldn't get IJob interface or writing IAudit: Pipe exception. Reason: jobserverchild (WebIJavaSchedulingService ReplicationSchedulingService, 0, Timeout waiting for Child [4716] to register ([120]seconds).
    Reproducing the Issue
    Install Business Objects Enterprise XI 3.x on a French Windows 2003 SP2 32bits server
    Install the following Microsoft windows update patches of April 2009:
    KB923561, KB925336, KB952004, KB956572, KB959426, KB960225, KB960803, KB961373, KB967715
    Schedule a WebIntelligence report
    The report remains in Pending status
    Business Objects Enterprise XI 3.1
    Windows 2003 SP2 32bit (French)
    Microsoft windows patches of April 2009
    Cause
    With Microsoft windows patches of April 2009, the maximum Heap Size for java processes has been reduced to under 1000MB.
    Resolution
    Apply the following steps to fix the issue:
    Launch the Central Management Console
    Select Servers
    Right click on <server_name>.Adaptive Job Server and select Properties
    Add the switch -javaArgs "Xmx900m,Xincgc,server" in the command line of the server
    Click on Save and Close
    Restart the <server_name>.Adaptive Job Server
    Regards .
    Sam.
    Edited by: samouber on Aug 21, 2009 2:54 PM

  • Generation PDF Report with Graph 6i

    Hello all of u,
    I have a problem to Generate 6i report with pie Graph in PDF format ,,
    Report run well and at the bottom show the pie graph with different color
    But when I Generate a PDF file, graph did not show and only back circle show
    What is the problem with the oracle graph and why color did not shown?
    Please help me
    Thanks to all

    Hi Julie,
    Sorry my english.
    I will try to explain in more details the problem.
    I have identified that the bar code name into the PDF output is lowercase (mw6code39mt).
    I only visualize or print the PDF output with the bar code when I manually alter that bar code name from lowercase to uppercase (MW6Code39MT).
    I do that in my Unix server using the vi editor.
    Please, see what I need to alter in the PDF output file on Unix server:
    <</Type /Font
    /Name /F1
    /Subtype /Type1
    /Encoding /WinAnsiEncoding
    /BaseFont /mw6code39mt ====> alter to MW6Code39MT
    /FirstChar 24
    /LastChar 255
    /Widths 9 0 R
    /FontDescriptor 10 0 R
    >>
    endobj
    Thank you.
    Edson

  • Report Engine crashing on Solaris when report with graph is given.

    Hi,
    We are using following environment:
    Solaris 8
    Oracle 9i Report Sevices.
    When we try to execute reports having graphs then the report engine crashes with the following exception:
    REP-0177: Error while running in remote server
    REP-56048: Engine rwEng-0 crashed
    The complete crash log is also appendend in the end of this mail.
    When I remove the graph from the rdf then reports get exectued fine without any crash. The same rdg with graph works fine on windows NT.
    If somebody can help on this, it will be great.
    Thanks,
    Ashish
    The complete crash log is as follows:
    An unexpected exception has been detected in native code outside the VM.
    Unexpected Signal : 11 occurred at PC=0xf017b350
    Function name=_Xm21FreeHashTable
    Library=/usr/lib/libXm.so.4
    Current Java thread:
         at sun.awt.motif.MWindowPeer.create(Native Method)
         at sun.awt.motif.MComponentPeer.init(MComponentPeer.java:169)
         at sun.awt.motif.MWindowPeer.init(MWindowPeer.java:86)
         at sun.awt.motif.MFramePeer.<init>(MFramePeer.java:53)
         at sun.awt.motif.MToolkit.createFrame(MToolkit.java:138)
         at java.awt.Frame.addNotify(Frame.java:353)
         at java.awt.Window.pack(Window.java:369)
         at tdg.Perspective.<init>(Perspective.java:478)
         at oracle.dss.graph.PFJ.<init>(PFJ.java:47)
         at oracle.dss.graph.Graph.createPFJ(Graph.java:1190)
         at oracle.dss.graph.Graph._setupGraphView(Graph.java:353)
         at oracle.dss.graph.Graph.<init>(Graph.java:164)
         at oracle.reports.chart.Chart.<init>(Chart.java:51)
         at oracle.reports.chart.ChartRunner.<init>(ChartRunner.java:46)
         at oracle.reports.engine.EngineImpl.CRunReport(Native Method)
         at oracle.reports.engine.EngineImpl.run(EngineImpl.java:289)
         at oracle.reports.engine.EngineClassPOATie.run(EngineClassPOATie.java:84)
         at oracle.reports.engine.EngineClassPOA._invoke(EngineClassPOA.java:117)
         at oracle.reports.engine.EngineClassPOA._invoke(EngineClassPOA.java:62)
         at com.inprise.vbroker.poa.POAImpl.invoke(POAImpl.java:2355)
         at com.inprise.vbroker.poa.ActivationRecord.invoke(ActivationRecord.java:104)
         at com.inprise.vbroker.GIOP.GiopProtocolAdapter.doRequest(GiopProtocolAdapter.java:492)
         at com.inprise.vbroker.IIOP.ServerProtocolAdapter.doRequest(ServerProtocolAdapter.java:64)
         at com.inprise.vbroker.GIOP.GiopProtocolAdapter.dispatchMessage(GiopProtocolAdapter.java:653)
         at com.inprise.vbroker.orb.TPDispatcherImpl$TPDispatcher.run(TPDispatcherImpl.java:99)
         at com.inprise.vbroker.orb.ThreadPool$PoolWorker.run(ThreadPool.java:76)
    Dynamic libraries:
    0x10000      /users/orarep9i/OraHome1/jdk/jre/bin/../bin/sparc/native_threads/java
    0xff350000      /usr/lib/libthread.so.1
    0xff390000      /usr/lib/libdl.so.1
    0xff200000      /usr/lib/libc.so.1
    0xff330000      /usr/platform/SUNW,Ultra-60/lib/libc_psr.so.1
    0xfe480000      /users/orarep9i/OraHome1/jdk/jre/lib/sparc/client/libjvm.so
    0xff2d0000      /usr/lib/libCrun.so.1
    0xff1d0000      /usr/lib/libsocket.so.1
    0xff100000      /usr/lib/libnsl.so.1
    0xff0d0000      /usr/lib/libm.so.1
    0xff310000      /usr/lib/libw.so.1
    0xff0b0000      /usr/lib/libmp.so.2
    0xff080000      /users/orarep9i/OraHome1/jdk/jre/lib/sparc/native_threads/libhpi.so
    0xff040000      /users/orarep9i/OraHome1/jdk/jre/lib/sparc/libverify.so
    0xfe440000      /users/orarep9i/OraHome1/jdk/jre/lib/sparc/libjava.so
    0xfe410000      /users/orarep9i/OraHome1/jdk/jre/lib/sparc/libzip.so
    0xf3be0000      /users/orarep9i/OraHome1/jdk/jre/lib/sparc/libnet.so
    0xf3bc0000      /users/orarep9i/OraHome1/jdk/jre/lib/sparc/libioser12.so
    0xf39e0000      /usr/lib/nss_nis.so.1
    0xf2000000      /users/orarep9i/OraHome1/lib/librw90.so
    0xf1d00000      /users/orarep9i/OraHome1/lib/libobx90.so.0
    0xf36b0000      /users/orarep9i/OraHome1/lib/librws90.so.0
    0xf2a80000      /users/orarep9i/OraHome1/lib/libde90.so.0
    0xf2fc0000      /users/orarep9i/OraHome1/lib/libucol90.so.0
    0xf39b0000      /users/orarep9i/OraHome1/lib/libuicc90.so.0
    0xf2ea0000      /users/orarep9i/OraHome1/lib/libca90.so.0
    0xf35e0000      /users/orarep9i/OraHome1/lib/libmma90.so.0
    0xf2dc0000      /users/orarep9i/OraHome1/lib/libmmiw90.so.0
    0xf3860000      /users/orarep9i/OraHome1/lib/libmmov90.so.0
    0xf2f90000      /users/orarep9i/OraHome1/lib/libmmos90.so.0
    0xf2cc0000      /users/orarep9i/OraHome1/lib/libmmoi90.so.0
    0xf32e0000      /users/orarep9i/OraHome1/lib/libmmia90.so.0
    0xf2da0000      /users/orarep9i/OraHome1/lib/libmmft90.so.0
    0xf1fc0000      /users/orarep9i/OraHome1/lib/libmmcm90.so.0
    0xf1c00000      /users/orarep9i/OraHome1/lib/libvgs90.so.0
    0xf2ca0000      /users/orarep9i/OraHome1/lib/libuihx90.so.0
    0xf1b90000      /users/orarep9i/OraHome1/lib/libuc90.so.0
    0xf1b20000      /users/orarep9i/OraHome1/lib/libuipr90.so.0
    0xf1900000      /users/orarep9i/OraHome1/lib/libuimotif90.so.0
    0xf1ae0000      /users/orarep9i/OraHome1/lib/libot90.so.0
    0xf18a0000      /users/orarep9i/OraHome1/lib/librem90.so.0
    0xf1820000      /users/orarep9i/OraHome1/lib/libree90.so.0
    0xf1fa0000      /users/orarep9i/OraHome1/lib/librec90.so.0
    0xf17f0000      /users/orarep9i/OraHome1/lib/libuiimg90.so.0
    0xf17b0000      /users/orarep9i/OraHome1/lib/libuia90.so.0
    0xf2a60000      /users/orarep9i/OraHome1/lib/libtknqap90.so.0
    0xf1780000      /users/orarep9i/OraHome1/lib/libutt90.so.0
    0xf1750000      /users/orarep9i/OraHome1/lib/librod90.so.0
    0xf1720000      /users/orarep9i/OraHome1/lib/libror90.so.0
    0xf16f0000      /users/orarep9i/OraHome1/lib/libros90.so.0
    0xf16c0000      /users/orarep9i/OraHome1/lib/libuat90.so.0
    0xf16a0000      /users/orarep9i/OraHome1/lib/libdfc90.so.0
    0xf1680000      /users/orarep9i/OraHome1/lib/libutc90.so.0
    0xf1660000      /users/orarep9i/OraHome1/lib/libutj90.so.0
    0xf1630000      /users/orarep9i/OraHome1/lib/libutl90.so.0
    0xf1610000      /users/orarep9i/OraHome1/lib/libsl90.so.0
    0xf0c00000      /users/orarep9i/OraHome1/lib/libclntsh.so.9.0
    0xf15f0000      /users/orarep9i/OraHome1/lib/libwtc9.so
    0xf15d0000      /usr/lib/libsched.so.1
    0xf15b0000      /usr/lib/libaio.so.1
    0xf0a00000      /usr/lib/libXm.so.3
    0xf1540000      /usr/lib/libXt.so.4
    0xf0900000      /usr/lib/libX11.so.4
    0xf1520000      /usr/lib/libgen.so.1
    0xf1500000      /usr/lib/librt.so.1
    0xf14e0000      /usr/lib/libSM.so.6
    0xf14b0000      /usr/lib/libICE.so.6
    0xf1480000      /usr/lib/libXext.so.0
    0xf0bd0000      /usr/openwin/lib/libdga.so.1
    0xf0bb0000      /users/orarep9i/OraHome1/jdk/jre/lib/sparc/libawt.so
    0xf0280000      /users/orarep9i/OraHome1/jdk/jre/lib/sparc/motif21/libmawt.so
    0xf09b0000      /users/orarep9i/OraHome1/jdk/jre/bin/../lib/sparc/libmlib_image.so
    0xf0000000      /usr/lib/libXm.so.4
    0xf08e0000      /usr/openwin/lib/libXtst.so.1
    0xeff00000      /users/orarep9i/OraHome1/jdk/jre/lib/sparc/libfontmanager.so
    0xf07a0000      /usr/openwin/lib/libdps.so.5
    Local Time = Fri Apr 18 09:22:09 2003
    Elapsed Time = 110
    # The exception above was detected in native code outside the VM
    # Java VM: Java HotSpot(TM) Client VM (1.3.1_02-b02 mixed mode)

    Please try the following
    * Modify $ORACLE_HOME/bin/reports.sh, replace "classic"
    with "server" in the LD_LIBRARY_PATH for the JVM
    * Modify $ORACLE_HOME/bin/rwengine.sh, just before the exec
    command, insert the following line:
    export LD_PRELOAD=$ORACLE_HOME/jdk/jre/lib/i386/libawt.so
    In Linux there was a similar problem and the above workaround worked . You can give this a try .
    Thanks
    The Oracle Reports Team

  • A big problem of Generate report with PDF format....Urgent

    I want to generate a report with pdf format through one java file, it have two page 1)gen_report.jsp 2) report_gen.java , the compliation was failed. However, i don't what the problem is .... i hope anyone can help me as it is very argent for me ....Thanks a lot
    1)gen_report.jsp
    <table  id="AutoNumber1">
       <tr>
         <td background="images/top5movie.png">
         <p align="center"> </p>
        </td>
       </tr>
       <tr>
       <td >
          <div align="center">
            <table id="AutoNumber2" >
                  <form method="GET" action="../report_gen" name="report_gen" target="_blank" onSubmit="javascript:return checkr1(this)">
                    <tr>
                      <td ><b>Report Description:</b></td>
                      <td >This report is to show the top five popular movies in cinemix for a period </td>
                    </tr>
                    <tr>
                      <td><b>Data scope:</b></td>
                      <td >Start from
                      <input type="text" name="start" value="2003-1-1" >to
                      <input type="text" name="end" value="2006-1-1" ></td>
                     </tr>
                     <tr>
                      <td><b>Data processing:</b></td>
                      <td >Show
                        <select name="order_by">
                          <option value="desc" selected>top</option>
                          <option value="asc">bottom</option>
                        </select>
                      5 films</td>
                    </tr>
                    <tr>
                      <td> <p align="center">
                          <input type="submit" value="View_Report" name="subm">
                        </p></td>
                    </tr>
                    <input type="hidden" name="report" value="r1">
                  </form>
                  <form method="GET" action="../report_gen" name="report_gen" target="_blank" onSubmit="javascript:return checkr2(this)">
                    <input type="hidden" name="report" value="r2">
                  </form>
                </table>
         </div>
          </td>
        </tr>
      </table>Then my java code is here
    report_gen.java
    import java.io.*;
    import java.net.*;
    import javax.servlet.*;
    import javax.servlet.http.*;
    import java.util.*;
    import java.sql.*;
    // chart and pdf out
    import java.awt.Graphics2D;
    import java.awt.geom.Rectangle2D;
    import java.io.FileNotFoundException;
    import java.io.FileOutputStream;
    import org.jfree.chart.ChartFactory;
    import org.jfree.chart.JFreeChart;
    import org.jfree.chart.plot.PlotOrientation;
    import org.jfree.data.category.DefaultCategoryDataset;
    import org.jfree.data.xy.*;
    import org.jfree.data.xy.XYBarDataset;
    import org.jfree.data.general.DefaultPieDataset;
    import org.jfree.data.statistics.SimpleHistogramDataset;
    import org.jfree.data.xy.XYSeries;
    import org.jfree.data.xy.XYSeriesCollection;
    import com.lowagie.text.Document;
    import com.lowagie.text.DocumentException;
    import com.lowagie.text.Rectangle;
    import com.lowagie.text.pdf.DefaultFontMapper;
    import com.lowagie.text.pdf.PdfContentByte;
    import com.lowagie.text.pdf.PdfTemplate;
    import com.lowagie.text.pdf.PdfWriter;
    import com.lowagie.text.*;
    import com.lowagie.text.pdf.*;
    import com.lowagie.text.pdf.PdfPCell;
    public class report_gen extends HttpServlet
       private final String titles[] = {"Top Five popular movies ",
                        "Financial cirumstance of cinemas",
                        "Distribution of time segment",
                        "Distribution of favourite movie type"
       private final String descs[] = {"This report is to show the top five  popular movies in cinemix for a period ",
                   "This report is to show the financial circumstance of each cinema site ",
                   "This report is to analysis the customer when is the most visit time ",
                   "This report is to analysis the customer which type of movie do they watch the most"
        private final String bigTitle = "Cinemix";
        private final String driver = "org.gjt.mm.mysql.Driver";
        private final String url= "jdbc:mysql://localhost:3306/cinemix";
        private final String userID = "abc";
        private final String passwd = "abc";     
        public void init(ServletConfig config) throws ServletException
          super.init(config);
       protected void doGet(HttpServletRequest request, HttpServletResponse response)
       throws ServletException, IOException
          final int width = 550;
         final int height = 200;
    / title font (centre and report title)
         final Font fTitle0 = FontFactory.getFont("Helvetica", 42, Font.BOLD);
         final Font fTitle1 = FontFactory.getFont("Helvetica", 30, Font.BOLD);
              // centre name:
        final String title0 = bigTitle;
       // Default category for DefaultCategoryDataset
       final String cat = "data";
       Connection conn;
      JFreeChart chart;
       String title1     = "xyz Report";
       String chartDesc = "description";
       String notes[] = new String[4];
       String chartTitle = "so bad this is title";
       String chartXTitle = "this is x";
       String chartYTitle = "this is y.";
       String report = request.getParameter("report");     
       int max=-10000;
       int min=10000;
       int j=0;          
      // do some basic checking
       if (report == null || report.equals(""))
         report = "-1";  // this course unknow report error message
         String start   = request.getParameter("start");
         String end  = request.getParameter("end");
         String order_by  = request.getParameter("order_by");  // ToDo: check invalid string
           int topN  = 5;
        String order = (order_by.equals("desc")) ? "Top" : "Last";
       String inv[] = {"08:30", "09:30", "10:30", "11:30", "12:30", "11:30", "12:30", "13:30", "14:30", "15:30", "16:30", "17:30","18:30","19:30","20:30","21:30","22:30","23:30"};
         int inv_val[] = new int[inv.length - 1];
         try
            Class.forName(driver).newInstance();
             catch(Exception e)
            printE("Cannot load mysql database driver!", response);
              e.printStackTrace();
               return;
           try
                 conn = DriverManager.getConnection(url, userID, passwd);
                  if (report.equals("r1")) {  // report 1
               DefaultCategoryDataset dataset = new DefaultCategoryDataset();
              Statement stmt = conn.createStatement();
              String sql = "select *,count(f.Name),f.Name from film f, filmDetail fd, ticket t where f.startDate > '" + start + "' and f.endDate <  '" + end + "'and fd.filmID = f.filmID and fd.filmDetailID = t.filmDetailID group by f.name order by fd.filmDetailID asc limit '" +topN+"'";
              ResultSet rs = stmt.executeQuery(sql);
            while (rs.next())
           if (rs.getInt("fd.filmDetailID") > max) max = rs.getInt("fd.filmDetailID");
         if (rs.getInt("fd.filmDetailID") < min) min = rs.getInt("fd.filmDetailID");
          j++;
           ataset.setValue(rs.getInt("fd.filmDetailID"), cat,rs.getString("f.Name"));
           title1     = titles[0];
         chartDesc  = descs[0];
         chartTitle = order + " " + topN + " popular movie";
          chartYTitle = "Box Office record";
          chartXTitle = "Film Name";
          gender = " ";
          chart = ChartFactory.createBarChart(chartTitle, chartXTitle,   chartYTitle, dataset,PlotOrientation.VERTICAL, false, true, false);
        else
              print("Error: I don't inderstand your request!", response);
         return;
           catch (SQLException e)
         printE("Cannot open database connection? <br>", response);
         // printE(e.toString);
      e.printStackTrace();
      return;
         response.setContentType("application/pdf");
         Document document = new Document(PageSize.A4, 5, 5, 5, 5);
        try
             PdfWriter writer;
         writer = PdfWriter.getInstance(document, response.getOutputStream());
        HeaderFooter footer = new HeaderFooter(new Phrase("Page: "), true);
         footer.setBorder(Rectangle.NO_BORDER);
    document.setFooter(footer);
                   footer.setAlignment(Element.ALIGN_CENTER);
                   // step 3
                   document.open();
                   document.add(getHeader(title0, title1, start, end, gender, order, topN, chartDesc));
                   document.add(printChart(chart, writer));
                   document.add(getFooter(notes));
              catch(DocumentException de)
                   de.printStackTrace();
              // step 5
              document.close();
              return;
         }// end doGet()
         /** Handles the HTTP <code>POST</code> method.
          * @param request servlet request
          * @param response servlet response
         protected void doPost(HttpServletRequest request, HttpServletResponse response)
              throws ServletException, IOException
              // processRequest(request, response);
         /** Returns a short description of the servlet.
         public String getServletInfo()
              return "Generate reports for " + bigTitle;
         /* To print en error and exit(?) */
         private void printE(Object obj, HttpServletResponse response) throws IOException
              response.setContentType("text/html");
              PrintWriter out;
              out = response.getWriter();
              out.print(obj.toString());
              out.close();
              // To-Do: how to force exiting?
         // create data chart
         private PdfPTable getHeader(String title0, String title1, String start, String end, String sex, String order, int topN, String desc)
              Font fTitle0 = FontFactory.getFont("Helvetica", 42, Font.BOLD);
              Font fTitle1 = FontFactory.getFont("Helvetica", 24, Font.BOLD);
              Font fTitle3 = FontFactory.getFont("Helvetica", 12, Font.BOLD);
              Font fValue = FontFactory.getFont("Helvetica", 12, Font.UNDERLINE);
              Paragraph parStartEnd = new Paragraph();
              parStartEnd.add(new Phrase("Data start from:                  ", fTitle3));
              parStartEnd.add(new Phrase(start, fValue));
              parStartEnd.add(new Phrase("     to     ", fTitle3));
              parStartEnd.add(new Phrase(end, fValue));
              Paragraph parGenerateDate = new Paragraph();
              parGenerateDate.add(new Phrase("Report generated at:         ", fTitle3));
              parGenerateDate.add(new Phrase(new java.util.Date().toString(), fValue));
              Paragraph parGender = new Paragraph();
              parGender.add(new Phrase("Current show gender:       ", fTitle3));
              parGender.add(new Phrase(sex, fValue));
              Paragraph parTopN = new Paragraph();
              parTopN.add(new Phrase("Now is showing                 ", fTitle3));
              parTopN.add(new Phrase(order, fValue));
              parTopN.add(new Phrase("  ", fValue));
              parTopN.add(new Phrase(new Integer(topN).toString(), fValue));
              parTopN.add(new Phrase("   record(s)", fTitle3));
              // Start main table
              PdfPTable tblMain = new PdfPTable(1);
              tblMain.getDefaultCell().setBorder(0);
              // Print title
              tblMain.getDefaultCell().setHorizontalAlignment(Element.ALIGN_CENTER);
              tblMain.addCell(new Paragraph(title0, fTitle0));
              tblMain.addCell(new Paragraph(title1, fTitle1));
              tblMain.addCell("");
              tblMain.addCell("");
              tblMain.addCell("");
              // Print headers data
              //tblMain.getDefaultCell().setHorizontalAlignment(Element.ALIGN_RIGHT);
              //tblMain.addCell(parInvoiceNum);
              //tblMain.addCell("");
              tblMain.getDefaultCell().setHorizontalAlignment(Element.ALIGN_LEFT);
              tblMain.addCell(parStartEnd);
              tblMain.addCell("");
              tblMain.addCell(parGenerateDate);
              tblMain.addCell("");
              if (sex != " ")
                   tblMain.addCell(parGender);
              else if(order != null && topN > 0)
                   tblMain.addCell(parTopN);
              else
                   tblMain.addCell(" \n");
              tblMain.addCell("");
              tblMain.setWidthPercentage(96);
              tblMain.addCell(new Paragraph("Description of this report:", fTitle3));
              tblMain.addCell(desc);
              tblMain.addCell("\n");
              // Finish main table
              return tblMain;
         // print a chart _directly_ to pdf and return a empty Pdftable...
         public PdfPTable printChart(JFreeChart chart, PdfWriter writer)
              PdfContentByte cb = writer.getDirectContent();
              int width = 550;
              int height = 450;
              PdfTemplate tp = cb.createTemplate(width, height);
              Graphics2D g2d = tp.createGraphics(width, height, new DefaultFontMapper());
              Rectangle2D r2d = new Rectangle2D.Double(0, 0, width, height); //->,
              chart.draw(g2d, r2d);
              g2d.dispose();
              cb.addTemplate(tp, 20, 170);
              // quick method to push down the footer text
              // the only things this method return
              PdfPTable tblDownDown = new PdfPTable(1);
              tblDownDown.getDefaultCell().setBorder(0);
              tblDownDown.addCell(" \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n");
              tblDownDown.addCell(" \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n");
              tblDownDown.addCell(" \n \n \n \n \n \n");
              return tblDownDown;
         public PdfPTable getFooter(String notes[])
              Font fNote = FontFactory.getFont("Helvetica", 14, Font.UNDERLINE);
              Font fComment = FontFactory.getFont("Helvetica", 12, Font.ITALIC);
              Font fTitle1 = FontFactory.getFont("Helvetica", 30, Font.ITALIC);
              // Start footer table
              PdfPTable tblFooter = new PdfPTable(1);
              tblFooter.getDefaultCell().setBorder(0);
              if (notes != null)
                   tblFooter.addCell(new Paragraph("Notes:", fNote));
                   tblFooter.addCell("");
                   tblFooter.addCell("");
                   tblFooter.getDefaultCell().setHorizontalAlignment(Element.ALIGN_LEFT);
                   for (int i=0;i<notes.length;i++)
                        if (notes[i] != null)
                             tblFooter.addCell(new Paragraph("" + (i+1) + ". " + notes[i] + "", fComment));
                             tblFooter.addCell("");
                             tblFooter.addCell("");
                        tblFooter.getDefaultCell().setHorizontalAlignment(Element.ALIGN_CENTER);
                        tblFooter.addCell(new Paragraph("- End of report -", fComment));
                        return tblFooter;
    }

    Go to the cache directory and see if you can open the report directly from here (not in IE).
    I have seen posts on problems with Acrobat Reader Plugin for IE (I believe it was version 6 of Reader).

  • Print Reports with CUPS

    Hi people,
    I have forms 11g and i'm trying to print reports directly to a printer that is installed on the server in CUPS via samba. I can print to my printer from os. Example, i open a pdf and it prints. In oracle reports, i run the report successfully and it prints but in blank. The report is well created in reports cache. Anyone know what can i do?
    p.s: don't know if i got it right placing my question here...Maybe in the reports forum?
    Edited by: user12231131 on 16/Jun/2011 9:20

    The problem seems to be Oracle Forms or Report related.
    There is a Forms forum at Forms
    and Report Reports

  • Print report with diferent dimensions

    i need print a report that print a page
    with exatly 6.7x4.0 inches and stop. i make a report in report 6i windows nt and my printer don't have a custom settings. only a4 letter and b5. I have a continous page on printer and i need that the report stop when finished print 4.0 height

    Hi,
    You can go ahead. The max. size is <b>1023</b> chars.
    REPORT zfr1000g
           NO STANDARD PAGE HEADING
           LINE-SIZE 999
           MESSAGE-ID fr.
    Regards,
    Anjali.
    Refer the Documentation on Reports.
    ... LINE-SIZE col
    Effect
    Creates a report with col columns per line.
    If the LINE-SIZE specification is missing, the line length corresponds to the current screen width. The system field SY-LINSZ contains the current line size for generating lists. The maximum width of a list is 1023 characters. You should keep lists to the minimum possible size to improve useability and performance (recommendation: LINE-SIZE < 132). For very wide lists (LINE-SIZE > 255), you should consult the notes for using LINE-SIZE

  • Print report with line-size 999

    Hi everyone,
    I need to print a report with line-size 999 in letter size. I´m using the complete 999 lines.
    REPORT zfr1000g MESSAGE-ID fr
                    LINE-SIZE   999
                    NO STANDARD PAGE HEADING.
    ANY SUGGESTIONS???
    Thanks.

    Hi,
    You can go ahead. The max. size is <b>1023</b> chars.
    REPORT zfr1000g
           NO STANDARD PAGE HEADING
           LINE-SIZE 999
           MESSAGE-ID fr.
    Regards,
    Anjali.
    Refer the Documentation on Reports.
    ... LINE-SIZE col
    Effect
    Creates a report with col columns per line.
    If the LINE-SIZE specification is missing, the line length corresponds to the current screen width. The system field SY-LINSZ contains the current line size for generating lists. The maximum width of a list is 1023 characters. You should keep lists to the minimum possible size to improve useability and performance (recommendation: LINE-SIZE < 132). For very wide lists (LINE-SIZE > 255), you should consult the notes for using LINE-SIZE

  • Problem in WEBI Report with PCM OLAP Universe (PCM MDX Connector)

    We need to create reports in Web Intelligence from our PCM Models (Business Objects Profitability and Cost Management). We are able to create the olap universe using PCM MDX Connector and we have no problems creating the reports in webi. The problem is when we execute the report (run query): all the data from PCM model is loaded correctly (dimensions, levels, etc.), except the Measures. I mean, the values of all the measures are always zero (0). No matter the way we change the query (adding filters, adding or chopping dimensions, drilling levels, etc.) the value for every measure is zero.
    We've checked the aggretation method of each measure in BO universe designer and are all correctly configured.
    The model in PCM is calculated and even when we run the queries in PCM Model Builder tool directly to the model, the results are retrieved Ok and the measures have correct values (Revenue, lineitem values, etc.).
    Any ideas of what is going on?

    Hi Henry… thanks for your answer…
    The reports we are creating of PCM are not from BW universes, but PCM OLAP Universes. PCM have its own cube OLAP files, and BO universes for those OLAP models use the Business Objects PCM MDX Driver.
    Nevertheless I will try to catch the MDX statement, as you suggest, and see if something is wrong with it.
    The versions we have are: “Business Objects Enterprise 12.3 build 601” and “Business Objects Profitability and Cost Management (PCM) 7.5.11”
    Thanks again.
    Vladimir.

  • Problems to print contacts with specific fields under Maverick.

    I am unable to print contacts with specific, selected fields like `firm´ or `position´under Mavericks. The selected fields will not show up in the printing preview and not be printed at all. Any ideas?

    Thanks, John! It seems you guessed correct, partly at least. I turned some of the problamatic fields off and on again an these are showing up now and I can print them. Great!
    However, I can see the field "firma" (German = company in English) in the previewed sample card but not in the pull down menu "Add Field". That means, I am unable to turn it off/on. The intersting thing: The field is visible and selectable even in the printer dialog were you can select the fields you would like to print but it remains unprintable.
    Again, many thanks, John! 

  • I need to make a report with graphs, and generate an exit file to word

    I have to do the acquisition for a laboratory and to make inmediately a report with graphics and a constant test about the method of the experimentation

    Probably your best bet is to use ActiveX and control Word from LabVIEW, this way, you can act as you were using Word directly, automating all the steps to create your report. Look for examples in the developer zone, although there will be more examples relating Excel, that can show you the way to act. If you need to use this intensively, i think NI has created a Word toolokit that you can buy.
    For any particular question, just ask.
    Good luck

  • Printing "REPORTS" with Quicken Deluxe 2006

    Installed Windows 7.  Cannot print "Reports" on HP  PSC 1410.  Can print Quicken "HELP" from same software

    Weeks ago.

Maybe you are looking for

  • Phone not working after upgrading apps

    upgraded 4 apps this morning, post which the mobile is not working, a few errors which are coming up are "uncaught exception application net_rim_bb_appworld(243) is not responding. process terminated"  also apperror 523 and it restars but most of the

  • Sound Clip

    I need help...how dom i create a sound clip on my itunes libary?

  • Apple Magic Mouse and Headset

    As soonas i run my Apple Magic Mouse together wit my samsung hm3100 my mouse is loosing the connection as soon as i switch of muy head set everything is fine Macbook Pro 17 inch snow 10.6.8 Any idea Thanx Frank

  • Date in File name

    Hi Experts, 1)Can i get the date only insted of timestamp. can anyone please tell me how can we achieve this. i did add one extra field and i map that field to current date and in CC i used variable substitution but i dont want that field in my file.

  • Lnguage specific code in a program

    Hi All, I have a requirement where i need to find the language specific code from a list of programs. please suggest me if there is any specific way to do this....... Regards, Ravi.. Edited by: ravi kumar on Nov 15, 2010 12:18 PM