Total Pages in System Variables?
Bosko
Belgrade, Serbia
Hi Alex,
I cannot get this value printed, it always prints 0 pages as number of Total Pages.
Is there some additional property that should be set, or this System Variable not working as I expected?
It would be nice if we could put that TotalPages to print something like "Page 2 of 6", but it always prints "Page 2 of 0".
Another question for FooterBand:
I have a FooterBand after DataBend, it works just fine for me, exactly what I needed, but, I need to print something else on one of TextBoxes in FooterBand on Last Page of a report.
So I tried to set a property "PrintOn", and exclude "Last Page", so I could print values on ReportSummaryBand, but it prints it again on Last Page.
I also tried to check if current page is actually last page of a report, but it failed, as I said, TotalPages variable, always returns 0;
Anyway, I need to replace default text for TextObject (that repeats on every page in FooterBand with some value) on a Last Page of a report?
For example:
I put TextObject on a FooterBand, with value of "Transfer", it prints it well on every page, but on last page of the report, printer TextObject's value should be "Summary".
Please, help somehow?
Thanks in advanced!
I cannot get this value printed, it always prints 0 pages as number of Total Pages.
Is there some additional property that should be set, or this System Variable not working as I expected?
It would be nice if we could put that TotalPages to print something like "Page 2 of 6", but it always prints "Page 2 of 0".
Another question for FooterBand:
I have a FooterBand after DataBend, it works just fine for me, exactly what I needed, but, I need to print something else on one of TextBoxes in FooterBand on Last Page of a report.
So I tried to set a property "PrintOn", and exclude "Last Page", so I could print values on ReportSummaryBand, but it prints it again on Last Page.
I also tried to check if current page is actually last page of a report, but it failed, as I said, TotalPages variable, always returns 0;
private void TextThatSholdBeSomethingElseOnLastPage_BeforePrint(object sender, EventArgs e)
{
if(((Int32)Report.GetVariableValue("Page"))==((Int32)Report.GetVariableValue("TotalPages")))
TextThatSholdBeSomethingElseOnLastPage.Text = "Summary";
}
Anyway, I need to replace default text for TextObject (that repeats on every page in FooterBand with some value) on a Last Page of a report?
For example:
I put TextObject on a FooterBand, with value of "Transfer", it prints it well on every page, but on last page of the report, printer TextObject's value should be "Summary".
Please, help somehow?
Thanks in advanced!
Comments
You need to set your report to double pass (menu "Report|Options...", "Double pass" checkbox). It will solve both problems (TotalPages and PrintOn).
Thank you, Alex, it solved both problems! [img]style_emoticons/<#EMO_DIR#>/biggrin.gif" style="vertical-align:middle" emoid=":D" border="0" alt="biggrin.gif" /> I didn't know about "DoublePass" property. Now report is exactly as it should be! Thank you![/img]