Jpeg to PDF

Jpeg to PDF

Postby Wanderson » Fri Mar 06, 2009 4:27 pm

Hi all,

I use Tscan32 class and works fantastic, but i want to transform a .jpeg picture saved by tscan32 to pdf document.
Any idea? I search in google about command line image converter but dont found any free solution.
Thanks in advance.
Wanderson.
Wanderson
 
Posts: 332
Joined: Thu Nov 17, 2005 9:11 pm

Re: Jpeg to PDF

Postby ukoenig » Fri Mar 06, 2009 6:45 pm

Hello,

You can use NCONVERT inside Your application in Command-line-mode
NCONVERT is free of charge

A sample :
same name with new format and resize ( TIFF to JPG ) :

cSCRIPT := "NCONVERT -out jpeg -resize 100 100 d:\T_VIEWER\IMAGE\A_LOGO1.TIFF"
WINEXEC ( "&cSCRIPT", 0 )

Download
http://www.brothersoft.com/nconvert-108781.html

Regards
Uwe :lol:
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
User avatar
ukoenig
 
Posts: 4043
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany

Re: Jpeg to PDF

Postby mmercado » Fri Mar 06, 2009 8:23 pm

Wanderson wrote:I use Tscan32 class and works fantastic, but i want to transform a .jpeg picture saved by tscan32 to pdf document.
Any idea? I search in google about command line image converter but dont found any free solution.
Thanks in advance.
Hi Wanderson:

You can do it directly from your FWH app usig TPdf class.

Here you can download TPdf class with a working xHarbour sample program: http://www.box.net/shared/qfbeha7cb7

Regards.

Manuel Mercado
manuelmercado at prodigy dot net dot mx
User avatar
mmercado
 
Posts: 782
Joined: Wed Dec 19, 2007 7:50 am
Location: Salamanca, Gto., México

Re: Jpeg to PDF

Postby reinaldocrespo » Fri Mar 06, 2009 9:54 pm

Manuel;

While you are on-line, would you mind helping with class tsbutton?

Recently one of my users discovered that by rightclicking on tsbar he can reproduce this error:

Error description: Error BASE/1004 Message not found: TSAY:LGROUP

Stack Calls
===========
Called from: => TSAY:ERROR(179)
Called from: tobject.prg => (b)HBOBJECT:HBOBJECT(105)
Called from: => TSAY:MSGNOTFOUND(0)
Called from: SAY.PRG => TSAY:LGROUP(167)
Called from: tsbar.PRG => TSBAR:BTNADJUST(284)
Called from: tsbar.PRG => TSBAR:GOLEFT(574)
Called from: tsbar.PRG => (b)TSBAR:RBUTTONDOWN(494)
Called from: MENU.PRG => TMENU:ACTIVATE(0)
Called from: tsbar.PRG => TSBAR:RBUTTONDOWN(507)
Called from: window.prg => TWINDOW:HANDLEEVENT(0)
Called from: CONTROL.PRG => TSBAR:HANDLEEVENT(0)
Called from: window.prg => _FWH(3160)
Called from: => WINRUN(0)
Called from: window.prg => TMDIFRAME:ACTIVATE(883)
Called from: main.prg => START(82)

I tried to copile the latest tsbutton but bpaint.c yields 17 errors.

Can you help?


Thank you,


reinaldo.crespo@gmail.com
User avatar
reinaldocrespo
 
Posts: 972
Joined: Thu Nov 17, 2005 5:49 pm
Location: Fort Lauderdale, FL

Re: Jpeg to PDF

Postby Wanderson » Fri Mar 06, 2009 10:09 pm

mmercado wrote:
Wanderson wrote:I use Tscan32 class and works fantastic, but i want to transform a .jpeg picture saved by tscan32 to pdf document.
Any idea? I search in google about command line image converter but dont found any free solution.
Thanks in advance.
Hi Wanderson:

You can do it directly from your FWH app usig TPdf class.

Here you can download TPdf class with a working xHarbour sample program: http://www.box.net/shared/qfbeha7cb7

Regards.

Manuel Mercado


Thanks Manuel but i receive this erros:

Turbo Incremental Link 5.00 Copyright (c) 1997, 2000 Borland
Error: Unresolved external '_compress' referenced from E:\LANG\FWH0805\XH1.1.0\LIB\RTL.LIB|hbcomprs
Error: Unresolved external '_uncompress' referenced from E:\LANG\FWH0805\XH1.1.0\LIB\RTL.LIB|hbcomprs
Error: Unresolved external '_zError' referenced from E:\LANG\FWH0805\XH1.1.0\LIB\RTL.LIB|hbcomprs
Wanderson
 
Posts: 332
Joined: Thu Nov 17, 2005 9:11 pm

Re: Jpeg to PDF

Postby Wanderson » Fri Mar 06, 2009 10:15 pm

ukoenig wrote:Hello,

You can use NCONVERT inside Your application in Command-line-mode
NCONVERT is free of charge

A sample :
same name with new format and resize ( TIFF to JPG ) :

cSCRIPT := "NCONVERT -out jpeg -resize 100 100 d:\T_VIEWER\IMAGE\A_LOGO1.TIFF"
WINEXEC ( "&cSCRIPT", 0 )

Download
http://www.brothersoft.com/nconvert-108781.html

Regards
Uwe :lol:


Thanks ukoening but nconvert dont makes pdf.
:(
Wanderson
 
Posts: 332
Joined: Thu Nov 17, 2005 9:11 pm

Re: Jpeg to PDF

Postby Wanderson » Fri Mar 06, 2009 10:32 pm

Wanderson wrote:
mmercado wrote:
Wanderson wrote:I use Tscan32 class and works fantastic, but i want to transform a .jpeg picture saved by tscan32 to pdf document.
Any idea? I search in google about command line image converter but dont found any free solution.
Thanks in advance.
Hi Wanderson:

You can do it directly from your FWH app usig TPdf class.

Here you can download TPdf class with a working xHarbour sample program: http://www.box.net/shared/qfbeha7cb7

Regards.

Manuel Mercado


Thanks Manuel but i receive this erros:

Turbo Incremental Link 5.00 Copyright (c) 1997, 2000 Borland
Error: Unresolved external '_compress' referenced from E:\LANG\FWH0805\XH1.1.0\LIB\RTL.LIB|hbcomprs
Error: Unresolved external '_uncompress' referenced from E:\LANG\FWH0805\XH1.1.0\LIB\RTL.LIB|hbcomprs
Error: Unresolved external '_zError' referenced from E:\LANG\FWH0805\XH1.1.0\LIB\RTL.LIB|hbcomprs


In link file i put the hbzip.lib and links well but i change nomina1.jpg in test program to myimage.jpg and not work, display a blank pdf page.

Thanks.
Wanderson
 
Posts: 332
Joined: Thu Nov 17, 2005 9:11 pm

Re: Jpeg to PDF

Postby Wanderson » Fri Mar 06, 2009 10:44 pm

Wanderson wrote:
ukoenig wrote:Hello,

You can use NCONVERT inside Your application in Command-line-mode
NCONVERT is free of charge

A sample :
same name with new format and resize ( TIFF to JPG ) :

cSCRIPT := "NCONVERT -out jpeg -resize 100 100 d:\T_VIEWER\IMAGE\A_LOGO1.TIFF"
WINEXEC ( "&cSCRIPT", 0 )

Download
http://www.brothersoft.com/nconvert-108781.html

Regards
Uwe :lol:


Thanks ukoening but nconvert dont makes pdf.
:(


Sorry, i tried: nconvert -out pdf myjpg.jpg and works well but the size of pdf is the same of jpg. My intention to save jpg to pdf is decrese the size.
Thanks.
Wanderson
 
Posts: 332
Joined: Thu Nov 17, 2005 9:11 pm

Re: Jpeg to PDF

Postby ukoenig » Fri Mar 06, 2009 11:46 pm

Hello Wanderson,

NCONVERT includes a very powerful Batch-language.
The line above is just a small sample what is possible.
You can visit the forum, to find a solution, if You need something special.

The brandnew version 5.5 You can download from here :
http://xnview.com/en/index.html

The forum ( You can ask for solutions there )
http://newsgroup.xnview.com/viewforum.p ... 5e88024987

Regards
Uwe :lol:
Last edited by ukoenig on Sat Mar 07, 2009 12:38 pm, edited 5 times in total.
Since 1995 ( the first release of FW 1.9 )
i work with FW.
If you have any questions about special functions, maybe i can help.
User avatar
ukoenig
 
Posts: 4043
Joined: Wed Dec 19, 2007 6:40 pm
Location: Germany

Re: Jpeg to PDF

Postby Wanderson » Fri Mar 06, 2009 11:53 pm

ukoenig wrote:Hello Wanderson,

NCONVERTS includes a very powerful scripting-language.
The line above is just a small sample what is possible.
You can visit the forum, to find a solution, if You need something special.

Regards
Uwe :lol:


Thanks ukoening i tried: Nconvert -out pdf -c 4 myimage.jpg and works great, reduce about 50%.
Wanderson
 
Posts: 332
Joined: Thu Nov 17, 2005 9:11 pm

Re: Jpeg to PDF

Postby mmercado » Sat Mar 07, 2009 6:25 am

reinaldocrespo wrote:I tried to copile the latest tsbutton but bpaint.c yields 17 errors.
Hi Reynaldo:

I can't reproduce the error you mention. Here you are SButtonx.rmk to build last version of SButtonx.lib with RMake.

Code: Select all  Expand view
// defining some preprocessor directives for bcc32
Def ="__HARBOUR__"

// defining paths
BC ="c:\bcc55"
FW ="c:\FWH"
HB ="c:\xHarbour"
makepath[.prg] ="..\source\classes"
makepath[.c] =".\;..\source\function"

.prg.c:
   $(HB)\bin\harbour $< /n  /i..\include;$(FW)\include;$(HB)\include > comp.log

.c.obj:
   $(BC)\bin\bcc32 -D$(Def) -O2 -c -I$(HB)\include;$(FW)\include $<  >> comp.log

TSButton.c     : TSButton.prg
TSBar.c        : TSBar.prg
TSLines.c      : TSLines.prg
TSRadio.c      : TSRadio.prg
TSTSay.c       : TSTSay.prg
TSGradie.c     : TSGradie.prg
TSButton.obj   : TSButton.c
TSBar.obj      : TSBar.c
TSLines.obj    : TSLines.c
TSRadio.obj    : TSRadio.c
TSTSay.obj     : TSTSay.c
TSGradie.obj   : TSGradie.c
BPaint.obj     : BPaint.c
TSButton.exe   : BPaint.obj TSButton.obj TSBar.obj TSLines.obj TSRadio.obj TSTSay.obj TSGradie.obj
                 Del SButtonX.lib
                 $(BC)\bin\Tlib SButtonX +TSButton  > Lib.log
                 $(BC)\bin\Tlib SButtonX +BPaint   >> Lib.log
                 $(BC)\bin\Tlib SButtonX +TSBar    >> Lib.log
                 $(BC)\bin\Tlib SButtonX +TSLines  >> Lib.log
                 $(BC)\bin\Tlib SButtonX +TSRadio  >> Lib.log
                 $(BC)\bin\Tlib SButtonX +TSTSay   >> Lib.log
                 $(BC)\bin\Tlib SButtonX +TSGradie >> Lib.log
                 Del *.c
                 Del *.obj
                 Del *.log
                 Del *.bak
 

Please let me know the result.

Best regards.

Manuel Mercado
manuelmercado at prodigy dot net dot mx
User avatar
mmercado
 
Posts: 782
Joined: Wed Dec 19, 2007 7:50 am
Location: Salamanca, Gto., México

Re: Jpeg to PDF

Postby reinaldocrespo » Sat Mar 07, 2009 1:57 pm

Manuel;

Gracias por la respuesta. Parece que has cambiado TsButton bastante. Yo no tengo Tsgradient. Seguramente es uno de los cambios. Me puedes enviar todo o decirme de donde lo puedo tomar? Si me la vas a enviar, por favor envia a reinaldo.crespo@gmail.com.

Gracias.
User avatar
reinaldocrespo
 
Posts: 972
Joined: Thu Nov 17, 2005 5:49 pm
Location: Fort Lauderdale, FL

Re: Jpeg to PDF

Postby hua » Tue Mar 10, 2009 4:00 am

ukoenig wrote:Hello,
NCONVERT is free of charge


I think possibility exist that it's only free for non-commercial use as hinted here http://xnview.com/en/nconvert.html
FWH 11.08/FWH 19.12
BCC5.82/BCC7.3
xHarbour/Harbour
hua
 
Posts: 1038
Joined: Fri Oct 28, 2005 2:27 am

Re: Jpeg to PDF

Postby nageswaragunupudi » Sun May 24, 2009 4:13 pm

Mr Manuel Mercado
You can do it directly from your FWH app usig TPdf class.

Here you can download TPdf class with a working xHarbour sample program: http://www.box.net/shared/qfbeha7cb7

Regards.

Manuel Mercado

The TPdf class is able to covert jpg, tiff and png files only into pdf. Are you aware of any utility that can convert emf files into pdf ? Nconvert can do it, but I am looking for a library that I can link to my application.

Actually my requirement is to save print preview as pdf file.
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10248
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: Jpeg to PDF

Postby reinaldocrespo » Sun May 24, 2009 10:32 pm

nageswaragunupudi;

Look no further. Nothing is better than Image2Pdf. A .dll with a .prg that you can compile and link with you app royalty free. ...And the support is incredibly good.

http://www.utilitywarrior.com/Image-to-PDF-Dynamic-Link-Library-Versions.htm

Extremely good library. I recommend it without any reservations.


Reinaldo.
User avatar
reinaldocrespo
 
Posts: 972
Joined: Thu Nov 17, 2005 5:49 pm
Location: Fort Lauderdale, FL

Next

Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: Silvio.Falconi and 78 guests