Page 2 of 2

Re: JPG > PDF and viceversa

PostPosted: Thu Oct 10, 2013 5:40 pm
by Badara Thiam
Stefan,

I come back to see the third possibility, thanks

Re: JPG > PDF and viceversa

PostPosted: Thu Oct 10, 2013 9:19 pm
by Gale FORd
You can use PageScript 32 to create PDF files.

Re: JPG > PDF and viceversa

PostPosted: Thu Oct 10, 2013 11:00 pm
by Badara Thiam
PageScript is a good product also. I used it in the past when i develop for DOS.
I let it down because i have writted all functions needed under Windows to replace it,
for free space in my install packs and for have more direct acces to the printer (without PageScript Spooler).
Since, the work print is also more quick.

Re: JPG > PDF and viceversa

PostPosted: Fri Oct 11, 2013 3:59 am
by nageswaragunupudi
Are not others ways to create FWH PDFs without Office, and without this enormous capacity needed for one page, 4 mb ?


Yes, there are many other ways. Many third party print drivers or libraries, some free and some priced, are available, which produce better quality output with very compact size. It is the programmer's decision to use them and that might be a better decision where the project requires it.

Even I use my preferred libraries in the projects I personally develop for commercial purposes.

When a programmer decides to use his preferred method, it is recommended that he may assign his function to the codeblock TPreview():bSaveAsPDF, at the beginning of the Main() function.

Code: Select all  Expand view
TPreview():bSaveAsPDF := { |oPrev, cPDF, lPreview| CustomFunction( oPrev, cPDF, lPreview ) }


cPdf and lPreview are optional. The function should return the PDF file name created with path. Returning NIL indicates that PDF is not created.

There are cases when some programmers prefer not to use printer drivers or considers that a project does not justify the investment of the required time and/or money to incorporate a 3rd party library. In such cases FWH provides a last fall back option to export to PDF without using any 3rd party drivers or libraries.

FWH prefers not to depend on 3rd party drivers or external libraries for its own function.

There is probably scope for compaction of the output and we shall be working on it in due course. FWH also highly appreciates contribution of any original code for conversion of EMF to PDF, provided the code does not depend on any 3rd party libraries/drivers and not borrowed from any 3rd party source.

Re: JPG > PDF and viceversa

PostPosted: Fri Oct 11, 2013 6:32 am
by Badara Thiam
Rao,

Thank for yours explains. I shall share my work to FWH community, about conversion emf to pdf,
if i can help on this.

Best regards.

Re: JPG > PDF and viceversa

PostPosted: Fri Oct 11, 2013 1:38 pm
by Gale FORd
PageScript32 can output to PDF or EMF. It is DLL based so there is no special installation or .com to register.

Here is help file for setting what type of output.
Syntax

PSSetDevice(nDevice)
TPageScript:SetDevice(nDevice)

Returns

NIL.

Description

Use PSSetDevice() to select the device to use for the next print job. By default, the device is DEV_PRINTER.

Arguments
nDevice Desired device for the next print job.

Devices
Constant Value Description
DEV_PRINTER 1 The output is sent to the selected printer.
DEV_PREVIEW 2 The output is sent to the print preview dialog box
DEV_PDFFILE 3 The output is saved in a .pdf file. The file name is set by calling PSSetFileName() before starting the print job.
Reserved 4 Reserved for future use
DEV_EMFFILE 5 The output is saved in a series of EMF files. The path of the files to be created is set by calling PSSetFileName() before starting the print job. Files are named Page1.emf, Page2.emf, Pagen.emf

Re: JPG > PDF and viceversa

PostPosted: Fri Oct 11, 2013 2:44 pm
by Badara Thiam
There is no problem to translate this function in Clipper, just STATIC global variable.

Re: JPG > PDF and viceversa

PostPosted: Sat Oct 12, 2013 5:02 pm
by Badara Thiam
Like this :
Code: Select all  Expand view

*******************
FUNCTION PSSetDevice( nDevice )
*******************
* Mémorise le type de sortie : Directe, vue avant impression, .pdf
* Si nDevice = 1 : la sortie est envoyée vers l'imprimante (direct printing)
* Si nDevice = 2 : la sortie est envoyée vers la vue avant impression (Preview)
* Si nDevice = 3 : la sortie est enregistrée dans un fichier .pdf. Le fichier doit être défini avec PSSetFileName() avant de démarer le travail d'
impression
* Retourne : NIL si nDevice n'est pas NIL, ou la valeur actuelle si nDevice est NIL
STATIC nDev := 1
IF nDevice = NIL
    RETURN nDev
ENDIF
nDev := nDevice
RETURN NIL

Re: JPG > PDF and viceversa

PostPosted: Tue Apr 01, 2014 9:12 am
by fp
The end of PageScript: http://www.abeelabs.com/ ?

Re: JPG > PDF and viceversa

PostPosted: Tue Apr 01, 2014 9:16 am
by Badara Thiam
fp wrote:The end of PageScript: http://www.abeelabs.com/ ?

Not today... this is a great work!