Re: Write Pro Print Preview...

2019-07-08 Thread Tom Benedict via 4D_Tech
I have discovered that Print Preview is not appearing because my code is 
running ‘inside’ of OPEN PRINTING JOB, which requires that all printer setup, 
including Print Preview, be done prior to calling OPEN PRINTING JOB.

Tom

> On Jul 7, 2019, at 15:09, Tom Benedict  wrote:
> 
> I’m trying to get a reliable print preview support in 4D Write Pro. This blog 
> posting https://blog.4d.com/4d-write-pro-wp-commands-and-beyond/ 
>  says:
> 
> "So 4D’s printing commands also apply to 4D Write Pro, such as SET PRINT 
> PREVIEW 
> ."
> 
> The posting includes some code:
> 
>   ALL RECORDS([People])   
>   SET PRINT PREVIEW(True)  
>   OPEN PRINTING JOB
>   APPLY TO SELECTION([People];WP PRINT([WP_Samples]Sample))
>   CLOSE PRINTING JOB
> 
> But the I run it I don’t get a Print Preview. I’m wondering whether this 
> Print Preview is dependent on printer driver rather than something internal 
> to 4D?
> 
> 17R4 64bit
> 
> Tom Benedict
> 
> 

**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

RE: Write Pro print preview

2018-12-31 Thread David Ringsmuth via 4D_Tech
SET PRINT OPTION(Destination option;2;$pdfpath)

“2” seems to do a print preview.



David Ringsmuth

From: David Ringsmuth
Sent: Monday, December 31, 2018 9:32 AM
To: 4D iNug Technical
Subject: Write Pro print preview

4D v17 R2 32bit and 64bit
Windows 10 (current)

At first and sometimes while using different features, I get a print preview.

But now I mostly get a Save File dialog when executing WP Print.

$pdfprintername:="Microsoft Print to PDF"
…
SET CURRENT PRINTER($pdfprintername)
SET PRINT OPTION(Destination option;3;$pdfpath)// pdfpath is a valid path to 
the temporary folder and a unique new file name.
SET PRINT PREVIEW(True)
WP USE PAGE SETUP($WP_Area_ob)
WP PRINT($WP_Area_ob;wk html wysiwyg)

Amazingly when using the library toolbar for WP, there is a “Print Preview” 
button with a “Standard Action” of “Print” that does a print preview. So the 
form’s sub-form standard action of “print” does a print preview? Yup.

I need it to always work correctly.

Please help!

Thanks!

David Ringsmuth


**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**