Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
THRUST SERVICES & TOOLS
CLOUD EDITIONS
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
dynamic visibility of GRID
birtguru
hi,
i want to control the visibility of the grid dynamicaly can any one help me please....
without consuming space
Find more posts tagged with
Comments
CBR
Select the grid. Go to Visibility tab in property editor. You can specify a condition that should return a value of true or false. If the expression you provided returns true the grid will be hidden (it doesn't consume any space). If it returns false it will be visible.
the only thing to remember is that all elements in the grid are generated. The visibility feature only prevents the grid and its content from rendering.
If your grid contains complex elements that take minutes to generate your reports won't be any faster if you use visibility feature to hide the grid and its content.
birtguru
hi,
i want to control the visibility of the grid dynamicaly can any one help me please....
without consuming space
here is the attachment.that is what i want in my report.please see the footers.....
birtguru
thanks,but i have a different problem.please see the attachment....
birtguru
hi
i want to create a pdf report like where 1st page has different footer and 2nd page has different footer.
there is a dynamic table on the 1st page which can be continued on second page.please see the attachment pdf....please give me solution.can any one please provid me with a solution.i have earlier posted this but i am not able to resolve it..plese help.thanks in advance...
mwilliams
So, the table that is in the body of the page will continue to the back page? And you want the grid in the page footer to be different on page one and page two? Does each run of the report happen for only one customer? Or do you group this table and run it for multiple customers? Let me know. Also, what is your BIRT version?
birtguru
thanks.
my BIRT version is 3.7.2
i am running it for single customer as of now but I want to implement it for multiple customers.
mwilliams
Take a look at this report. Let me know if you have questions.
birtguru
thanks.
but the solution you have given is repeating the first page contents on the second page third page and so on......
I am generating reports in the form of PDF.i have defined auto PAGE BREAK option.
please try it with PDF's.
please reply.......i am waiting for your response.....
mwilliams
I designed the report, only looking at it in PDF, and it looks just fine, to me. Not sure what you're doing different, but in 3.7.2, if I run the report I attached, it works. I've not selected an order that has 3 pages, so I can't speak to that. I designed it with thought that there would only be 2 pages (the second page is forced if only 1). Let me know what order shows 3 pages and I'll take a look. Thanks.
birtguru
you are right, the second page is forced if only 1.like wise for page 3 is forced if only 2.but on page 3 we dont require any grid.your solution is working fine if i will define a page break after 5 or 6 like that row.
but if I select auto page break than it is not running as expected.it is repeating first page footer on every page...why so?
mwilliams
Again, I only designed the report as if there would be two pages. If you change the script in the master page footer grid rows just slightly to say if pageNumber != 1 and if pageNumber !=2, then the appropriate footer will only show on the first and second page. As for the page break interval I set. That was only set to make data actually go to 2 pages sometimes. The report works as expected if you set the page break interval to 0 and run in PDF with the frameset URL. If I have enough data to go to more than 2 pages, the 3rd page and beyond don't have either footer on them, just an empty box where the footer was. Make the above changes and be sure to run your PDF with frameset or separate run and render tasks if you're using java. Let me know.
birtguru
the main problem is that with auto(natural)page break pageNumber variable is not working for pdf...
mwilliams
It works for me. If you try to run it straight to PDF from the run as drop down, it will not work. If you run it in the viewer and export to PDF or use frameset in the url, to run it in pdf, it should work. Like I said, it works correctly for me, if I do this. Let me know.
birtguru
i am running it using java stand alone application. Even than it is not working...
is it necessary to run it in the viewer?
if so then then please tell me each and every step,that i need to do
as i think it is already reported as bug.please see the link given below...
http://www.eclipse.org/forums/index.php/mv/tree/175473/
is this bug is solved?
please provide me a solution.
thanks.
mwilliams
That should not be an issue in 3.7.2, as long as you're using a fixed layout, have your page break interval set to 0, and are using separate run and render tasks. If you're using the runAndRender task, you'll probably need to change it to run the separate run and render tasks. You should not need to run it in the viewer. The viewer simply uses the APIs, so anything the viewer can do, you should be able to do. Let me know.
birtguru
public class pdf {
public static void main(String arg[])
{
ExecuteReport("C:/Users/Sharma/Desktop/header.rptdesign");
}
public static void ExecuteReport(String reportDesign)
{
try {
EngineConfig config = new EngineConfig();
Platform.startup(config);
ReportEngine engine = new ReportEngine(config);
IReportRunnable reportRunnable = engine.openReportDesign(reportDesign);
IRunAndRenderTask runAndRender = engine.createRunAndRenderTask(reportRunnable);
PDFRenderOption option = new PDFRenderOption();
option.setOutputFileName("C:/Users/Sharma/Desktop/output_test.pdf");
option.setOutputFormat("PDF");
runAndRender.setRenderOption(option);
runAndRender.run();
runAndRender.close();
engine.destroy();
Platform.shutdown();
} catch (EngineException e) {
e.printStackTrace();
} catch (BirtException e) {
e.printStackTrace();
}
}
}
this is the JAVA program that I am using.
I have set the page break interval 0 or 40 but my problem still exist.
i.e pageNumber variable is always 1.
the following code do not work for 2nd page of pdf.it is repeating the 1st page grid.
if( pageNumber > 1 ){
this.getStyle().display = "none";
}
mwilliams
You're using the runAndRender task. You'll need to use separate tasks.
See this page for the separate tasks. It's kinda old, so it'll probably need to be updated slightly, but should get you started.
http://wiki.eclipse.org/Separate_Run_and_Render_(BIRT)_2.1
Here are the docs for IRunTask and IRenderTask
http://help.eclipse.org/indigo/index.jsp?topic=/org.eclipse.birt.doc.isv/engine/api/org/eclipse/birt/report/engine/api/IRunTask.html
http://help.eclipse.org/indigo/index.jsp?topic=/org.eclipse.birt.doc.isv/engine/api/org/eclipse/birt/report/engine/api/IRenderTask.html