Welcome to the nuBuilder Forums!

Register and log in to access exclusive forums and content available only to registered users.

How to create a Single Record Report with join clause

Questions related to nuBuilder Forte Reports and the Report Builder.
Janusz
nuBuilder Team
Posts: 506
Joined: Fri Dec 28, 2018 1:41 pm
Location: Krakow, Poland
Has thanked: 8 times
Been thanked: 18 times

Re: How to create a Single Record Report with join clause

Unread post by Janusz »

if for example you just want to have prefilled file name you can do following:

Make back-up of the nurunpdf.php file.

in the nurunpdf.php replace some code as following:

Code: Select all

replace: 
$PDF->Output('nureport.pdf', 'I');      (normally it's line 54)

with 4 lines as following:

$customer='Patricia';
$date = date('Y-m-d_H-i-s');
$file_name= 'Report_'.$customer.$date.'.pdf';
$PDF->Output($file_name, 'I');
next we can progess with reading actual customer name - but before that - I need to understand very clearly your needs.
If you like nuBuilder, please leave a review on SourceForge
nc07
Posts: 118
Joined: Tue Jun 04, 2019 4:05 am
Has thanked: 5 times
Been thanked: 22 times

Re: How to create a Single Record Report with join clause

Unread post by nc07 »

Thank you, Janusz, for your time and great help.

I changed the config to:

Code: Select all

$customer='Patricia';
$date = date('Y-m-d_H-i-s');
$file_name= 'Report_'.$customer.$date.'.pdf';
$PDF->Output($file_name, 'I');
and when I download, the file automatically names to above config...all works fine..that's what I was exactly asking for.

Secondly, as u have already mentioned, to retrieve values from the fields on the form namely (po_importer & po_ic)..which I would like to output name to include.
Janusz
nuBuilder Team
Posts: 506
Joined: Fri Dec 28, 2018 1:41 pm
Location: Krakow, Poland
Has thanked: 8 times
Been thanked: 18 times

Re: How to create a Single Record Report with join clause

Unread post by Janusz »

so now lets follow with the subject in the other post I started (as it is more close to that)

https://forums.nubuilder.cloud/viewtopic.php?f=21&t=9905

to the above post I will send you soon the code which will make the link of your form with the PHP code.
If you like nuBuilder, please leave a review on SourceForge
Post Reply