Re: How to print a document from LEP?

2018-12-17 Thread Keisuke Miyako via 4D_Tech
if you have already figured out how to do it via the CLI,
you are just one step away from doing the same with LEP.

if the application (AcroRd32.exe in your case) does not run directly via LEP,
you probably need to start it via cmd.exe (the console application).

see ex.10

http://doc.4d.com/4Dv17/4D/17/LAUNCH-EXTERNAL-PROCESS.301-3729951.en.html

---

passing paths to LEP can be tricky, you can find a wrapper method here:

https://github.com/miyako/4d-component-sublaunch

or a plugin here:

https://github.com/miyako/4d-plugin-shell-execute

---

unlike macOS, Windows does not support direct printing of PDF.
you need to delegate to an app that had the capability to process PDF

https://github.com/miyako/4d-plugin-direct-print

2018/12/18 5:04、Bob Miller via 4D_Tech 
<4d_tech@lists.4d.com>のメール:

I know the path to Acrobat reader and to Excel.  I can print from both of
them by bringing up the command line (Windows) and typing in something
like C:\path_to_Acrobat\AcroRd32.exe /tor
c:\path_to_Excel\Excel.exe 

However, I can't get these to work with LEP.  I'm sure I'm missing
something fundamental.



**
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: How to print a document from LEP?

2018-12-17 Thread Darin Schroeder via 4D_Tech
Bob,

Is the printer you are using IP-based and understand PCL? If it is, we
basically turn the PDF into PCL using GhostScript (using LEP) and then push
the PCL to the printer using TCP commands.

This only works for PDF with GhostScript though. Maybe there's a PCL
convertor for other programs, but I'm not sure about that.

It's pretty straightforward ... TCP_Open, TCP_SendBLOB, TCP_Close.
Occasionally you may get an error with TCP_Open if the connection is
refused if the printer is busy, but a simple delay generally works the
second time around.

Darin



On Mon, Dec 17, 2018 at 2:04 PM Bob Miller via 4D_Tech <4d_tech@lists.4d.com>
wrote:

> Hi Everyone,
>
> This is a most fundamental thing, but I've now wasted enough time on it
> that I think that either I should take some time off OR lay off the
> holiday egg nog (maybe both).
>
> If I programatically create a file using 4D, such as an Acrobat PDF file
> or an Excel file, and then I want to print it from 4D-Windows (yes, we
> have users who want to have things waiting for them _on the printer_ in
> the morning), how can I do this?
>
> I know the path to Acrobat reader and to Excel.  I can print from both of
> them by bringing up the command line (Windows) and typing in something
> like C:\path_to_Acrobat\AcroRd32.exe /tor
> c:\path_to_Excel\Excel.exe 
>
> However, I can't get these to work with LEP.  I'm sure I'm missing
> something fundamental.
>
> Thoughts?
>
>
> Bob Miller
> Chomerics, a division of Parker Hannifin Corporation
>
>
> ll
> "PLEASE NOTE: The preceding information may be confidential or privileged.
> It only should be used or disseminated for the purpose of conducting
> business with Parker. If you are not an intended recipient, please notify
> the sender by replying to this message and then delete the information from
> your system. Thank you for your cooperation."
> **
> 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
> **
**
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
**

How to print a document from LEP?

2018-12-17 Thread Bob Miller via 4D_Tech
Hi Everyone,

This is a most fundamental thing, but I've now wasted enough time on it 
that I think that either I should take some time off OR lay off the 
holiday egg nog (maybe both).

If I programatically create a file using 4D, such as an Acrobat PDF file 
or an Excel file, and then I want to print it from 4D-Windows (yes, we 
have users who want to have things waiting for them _on the printer_ in 
the morning), how can I do this?

I know the path to Acrobat reader and to Excel.  I can print from both of 
them by bringing up the command line (Windows) and typing in something 
like C:\path_to_Acrobat\AcroRd32.exe /tor 
c:\path_to_Excel\Excel.exe 

However, I can't get these to work with LEP.  I'm sure I'm missing 
something fundamental. 

Thoughts?


Bob Miller
Chomerics, a division of Parker Hannifin Corporation


ll
"PLEASE NOTE: The preceding information may be confidential or privileged. It 
only should be used or disseminated for the purpose of conducting business with 
Parker. If you are not an intended recipient, please notify the sender by 
replying to this message and then delete the information from your system. 
Thank you for your cooperation."
**
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
**