|
javaprince (m)
|
Have you embedded a report in your Java Application? What tools are required it to achieve this in Java. For those who don't know, During the Visual Basic days, The IDE came in with Data reports. Later on people started integrating Crystal reports in their VB and .NET applications. My question is this how do u achieve d same effect in a Java Environment(e.g Netbeans). My Experience: In a bid to integrate Reporting with my Netbeans 6.1, I downloades iReports plug-in, I can now create reports(jrxml files) within netbeans. But my main problem is how do I call from my Java code to display the report? 2) How can I emebed the report inside my JFrame form. I need experienced Java Programmers to please share their experience with me. Thanks. Proud to be a JAND
|
|
|
|
|
|
javalove (m)
|
Well, i v never used netbeans before (can u believe that!!!) but i have it on my system sha. I use a small IDE and it gets my job done as at when due. I hope to start using it soon though so I can be seen as a "PROFESSIONAL" hisses . . . . as if i'm not already oneTalking about reporting, i also dont use iReport. I use ReportMill. www.reportmill.com. It's the best java reporting tool I know cos I have tried amost all the ones available from iReport, Datavision to Jasper, Reportmill is easy to use, handy API's to generate reports, a good page layout application for visual designs, with graphing and charting, cross tabs, mailing labels and other cool-ish stuffs u need. I have been using it for close to 4yrs and i will continue to use it,
|
|
|
|
|
|
Ghenghis (m)
|
Well, for generating reports with forms i've used Jasper reports(i.e Ireports). For web Business Objects(Java reporting Component). It creates an embedded report frame within your web UI, and its very good. Instead of the jrxm you still use .RPT files (crystal report templates). Checkout their site, i'm sure its the way to go.
(Eclipse has plugins for crystal reports design etc)
|
|
|
|
|
|
javaprince (m)
|
@Ghenghis and @javalove Thanks for the replies.
But you both failed to mention if I could embed any of the reports within a normal container class (e.g JPanels, JFrames, etc). Also, I need specific How to Do's and explanation on how to go about it. If possible sample codes.
Thank u very much.
Proud to be a JAND
|
|
|
|
|
|
javalove (m)
|
Sure, u can embed reportmill in any container u want, You can even export your reportd to PDF, Excel, Flash, HTML or any other, if u can make a simple HelloWorld, then u can use RM. It has a visual designer where u can design your reports and define the keys, When you are done, save it as a .rpt. See this when designing your report Employee Name: @getEmployeeName@ Employee Address: @getEmployeeAddress@ and so on, Then i your code you you can pass your datasets as a java.util.List, a Map or an Xml File. When you fetch your data from God-knows-where and say, just add dem to the map, Map myJavaDataset= new HashMap(); myJavaDataset.put("getEmployeeName", rs.getString(1).trim()); myJavaDataset.put("getEmployeeAddress", "Nairaland Avenue, Lagos");
//Load your report template
RMDocument template = new RMDocument(aSource);
//Generate the report passing your dataset as parameter
RMDocument report = template.generateReport(myJavaDataset);
//Genarate a pdf if u like
byte pdf[] = report.getBytesPDF();
//You can also just write it out:
report.write("MyReport.pdf");
//Make the viewer
RMViewer viewer= new RMViewer JScrollPane pane= new JScrollPane(viewer); getContentPane().add("Center",pane);
//Set the document viewer.setDocument(report);
Thats all u need to do, More examples are available on www.reportmill.com. Its just a single jar u add to your class path. You also need to download the studio for designing your reports and dats all, Jaji
|
|
|
|
|
|
javalove (m)
|
see the ones i made
|
|
|
|
|
|
javaprince (m)
|
@javalove Thanks for the hints. i visited the site and discovered that their products are for sale, although I was able to download an evaluation copy.
But am still workin on how to display the report forms wthin my JFrame/JPanel(i mean inside) just like when u add components such as JTable to a container.
Also am not sure which of the files I have to include in my classpath to be access the Classes provided therein.
All in all thanks.
Proud to be a JAND
|
|
|
|
|
|
donkay (m)
|
Faro, u dey M! wetin concern me and Java?
|
|
|
|
|
|
Mass Optin (m)
|
Hello, We have the pleasure to introduce ourselves as MassOptins.com, and we pride in being the one-stop shop for your email marketing solution. We have Email Lists, Optin Leads and Mailers (cPanel, Webmail, PHP Mailer & Software based versions. All our Mailer products are INBOX DELIVERY GUARANTEED. In case of Email Lists, you can choose to buy country-wise or category-wise (like home-owners, job-seekers, internet shoppers, students etc. So whatever your budget, or requirement, we will customize a list and/or mailer to suit your purpose. Here are the lists you can buy from us: http://www.massoptins.com/index2.htmlhttp://www.massoptins.com/morelists.htmlTo learn about how to make money on the internet - please go to our affiliate website http://www.topinternetdollars.com/articles/. Kind Regards Mike, MassOptins.com
|
|
|
|
|
|
javareport
|
@javaprince: I am facing the same problem as yours. Can you please help me in this regard? It will be very helpful for me. Thank you.
|
|
|
|
|
|
|
|
javajsf
|
hello all java experts,
i hv projects in vb and hv plenty of crystal reports designed and running in vb. now i hv developed the same in netbean 6.1 under jsf platform. all are working fine except my crystal report files. i m unable to integrate them with jsf in nb6.1. i know u all r here are java expert may be you hv already done this by this time. please help me any source code sample.
Thanking you all in advance
|
|
|
|
|
|