PDF Filename generated when using OnGetFilesuffix
Hi,
I am using Report Builder 12.05 Enterprise.
I am generating a PDF File for each group in a report using OnGetFileSuffix
procedure.
How can I get the location and PDF Filename created in RAP?
i.e. If the File suffix is Invoice_55_Customer_33 I would like to know also
the folder
( c:\temp\invoices\Inv_Invoice_55_Customer_33.pdf )
Is there a way to know the FileName created using RAP?
Thanks,
Jose Maria Sanmartin
I am using Report Builder 12.05 Enterprise.
I am generating a PDF File for each group in a report using OnGetFileSuffix
procedure.
How can I get the location and PDF Filename created in RAP?
i.e. If the File suffix is Invoice_55_Customer_33 I would like to know also
the folder
( c:\temp\invoices\Inv_Invoice_55_Customer_33.pdf )
Is there a way to know the FileName created using RAP?
Thanks,
Jose Maria Sanmartin
This discussion has been closed.
Comments
You can use the Report.FileDevice.FileName property to obtain the
initial file name and path to be used when exporting each group.
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
But using
ShowMessage(Report.FileDevice.Filename);
in RAP I get this error:
Expected: '(' or '[', but Filename was found instead.
Should I use a passthrough function to get access to Report.FileDevice?
Thanks,
José María Sanmartín
Your problem is with FileName property of FileDevice.
This property was published in RB 14 only.
So your code work without problems in RB 14 and later.
Rather than create your passthrough function, I recommend just creating a
RTTI class for TppFileDevice. Then your RAP code can use FileName and
later you can remove this custom RTTI for RB 14.
On Mon, 14 Jul 2014 09:30:49 +0300, Jose Maria Sanmartin
ReportBuilder has continued to evolve a long way since RB 12.x or earlier.
Please consider upgrading your ReportBuilder license regularly to take
advantage of this an hundreds of other improvements and enhancements. We
are a small team, the revenue from the product goes back into supporting
the RB community with tech support, bug fixes, and adding requested
features. We have a number of products we use here and upgrade them
every year, the authors are important to our business and we know they
need the support. It’s a win/win situation.
Here is a link to What's New for RB 15. (Use the side menu to see what
was new for prior releases)
http://www.digital-metaphors.com/rbWiki/General/What's_New/RB_15
Nico Cizik
Digital Metaphors
http://www.digital-metaphors.com
I have created a RTTI class for TppFileDevice with access to property
FileName.
When is the Filename changed after using OnGetfileSuffix and what method
should I use in RAP once FileName is setted?
Thanks,
Jose Maria Sanmartin
"Dima" escribi? en el mensaje
FileDevice.FileName do not change immediately after OnGetfileSuffix event.
This happens later, when device receive the Page (in
FileDevice.ReceivePage method).
No special method (event) available in RAP that raised on Filename changed.
But what is your problem? What you want to do?
On Fri, 18 Jul 2014 19:56:28 +0300, Jose Maria Sanmartin
I will check with ReceivePage method.
I want to generate a range of invoices in Pdf and then create an script to
send them by email (every invoice for each customer). For that I need to
know the PDF file name generated for every invoice.
As far as I know, ReportBuilder only sends 1 email for every report
generated, so I try to create a script to send the emails all at once.
Something like:
mailto: -address -subject -attach.
Regards,
Jose Maria Sanmartin
"Dima" escribio en el mensaje de noticias
If you need, I can try make some example for you some more later.
On Tue, 22 Jul 2014 14:49:16 +0300, Jose Maria Sanmartin
If it is no problem for you and it doesn't take too much of your time, you
can make an example for me.
Don't worry if you can't, because I am not at all convinced that this is the
way that I am going to implement it. Only if the solution save time to the
customer I would use it.
You can send it to chema at patopatin.com.
Thanks again,
Jose Maria Sanmartin
"Dima" escribio en el mensaje de noticias