1819718 Members
2948 Online
109606 Solutions
New Discussion юеВ

Re: HTML2PDF for VMS?

 
SOLVED
Go to solution
Clark Hayden
Advisor

HTML2PDF for VMS?

Hi.

We produce HTML files which contain some graphics and the business would now like to convert these to PDF which will then be e-mailed to the clients as attachments.

Is there a way to convert the HTML files to PDF within VMS that is freeware? I have managed to compile a C module to convert text to pdf bu cannot find anything on converting HTML to PDF for the VMS platform.

Thanks.
Hayden.
33 REPLIES 33
Brian Reiter
Valued Contributor

Re: HTML2PDF for VMS?

There's HTMLDOC which is on the Freeware 7 set of disks and is also included as part of the T4 installation.

cheers

Brian
P Muralidhar Kini
Honored Contributor

Re: HTML2PDF for VMS?

Hi Clark,

You can make use of the HTMLDOC freeware utility.

You can find it in the below link -
http://h71000.www7.hp.com/openvms/freeware/v7_00freeware_abstract.txt
>> HTMLDOC Translate HTML pages into Postscript or PDF

To download HTMLDOC or other utilities from Freeware V7, Refer
http://h71000.www7.hp.com/openvms/freeware/

That should meet your requirement.

Regards,
Murali
Let There Be Rock - AC/DC
Clark Hayden
Advisor

Re: HTML2PDF for VMS?

The HTMLDOC runs but I keep getting the follwoing error message:

ERR005: Unable to open font width file HTMLDOC_DATA/fonts/Times-Roman.afm!

Any ideas to remedy the problem? Or is this something I need to take up with our system administrator?

Thanks.
Volker Halle
Honored Contributor

Re: HTML2PDF for VMS?

Clark,

you have the sources available, have a look for this error message...

The font files seem to exist on the Freeware V7 CD, may it's just a missing HTMLDOC_DATA logical ?

Volker.
Bhadresh
Trusted Contributor

Re: HTML2PDF for VMS?

>>> ERR005: Unable to open font width file HTMLDOC_DATA/fonts/Times-Roman.afm!
>>>Any ideas to remedy the problem?

Error 5 indicates the specified file could not be found. HTMLDOC_DATA variable specifies the location of HTMLDOC's data and fonts directories. Have you set HTMLDOC_DATA?

Regards,
Bhadresh


Clark Hayden
Advisor

Re: HTML2PDF for VMS?

Yes, HTMLDOC_DATA has been set up to map to the correct directory. The problem seems to be that the app tags on "/fonts/..." to the location.

I've been scouring the web trying to find a solution but so far I have had no luck.

Any assitance will be greatly appreciated.

Thanks.
Hayden.
Volker Halle
Honored Contributor

Re: HTML2PDF for VMS?

Hayden,

does $ DIR HTMLDOC_DATA:[FONTS] show the font files ? If not, can you copy them there ?

Volker.
Andy Bustamante
Honored Contributor

Re: HTML2PDF for VMS?

Would you post the results of

$ show logical HTMLDOC_DATA


If you don't have time to do it right, when will you have time to do it over? Reach me at first_name + "." + last_name at sysmanager net
Clark Hayden
Advisor

Re: HTML2PDF for VMS?

Ok. I have extracted the files/directories from the Freeware V7 backups and have copied these to $DKE0:[HTMLDOC] on VMS, with $DKE0 being the disk.

I had to copy the HTMLDOC_IA64.EXE executable from another source since I could not find an executable image in the freeware files that would run.

I then set the HTMLDOC_DATA logical up as follows:
"HTMLDOC_DATA" = "$DKE0:[HTMLDOC]" (LNM$PROCESS_TABLE)

But I still get the ERR005 message that it cannot find the files.

Any tips?

PS: Volker, thanks for all your help so far.

Thanks.
Hayden.
Joseph Huber_1
Honored Contributor
Solution

Re: HTML2PDF for VMS?

I almost never used it, but htmldoc.com setup reads:
$! HTMLDOC.COM
$!
$! Customize this procedure as required for your installation.
$!
$! Note: use unix-style directory format for the HTMLDOC_DATA directory!
$!
$ define HTMLDOC_DATA "disk$www/htmldoc/
$!
$ HTMLDOC :== $DISK$WWW:[HTMLDOC]HTMLDOC.EXE
$!
$ exit

i.e defining htmldoc_data in VMS syntax is wrong.
Define it in Unix syntax:
define htmldoc_data "/device/htmldoc/"
to make it working.
A quick test on my system showed it is working.
http://www.mpp.mpg.de/~huber
Joseph Huber_1
Honored Contributor

Re: HTML2PDF for VMS?

In my above define command, there may be a variation of the Unix-style path definition,
depending on "device" being a logical name, and the definition of the Unix-compatibility level and the definition of
DECC$DISABLE_TO_VMS_LOGNAME_TRANSLATION

So either "/device/directory/"
or "device/directory".
http://www.mpp.mpg.de/~huber
Clark Hayden
Advisor

Re: HTML2PDF for VMS?

Hi Joseph.

I have tried defining the logical as:
"HTMLDOC_DATA" = "/ALEX04$DKE0/HTMLDOC"
"HTMLDOC_DATA" = "/ALEX04$DKE0/HTMLDOC/"
"HTMLDOC_DATA" = "ALEX04$DKE0/HTMLDOC"
"HTMLDOC_DATA" = "ALEX04$DKE0/HTMLDOC/"

None of which has returned anything other than ERR005: Unable to open font width file.........

I have no previous Unix experience so this is all a learning experience for me. :)

Thanks.
Hayden.
Oswald Knoppers_1
Valued Contributor

Re: HTML2PDF for VMS?

Maybe the html2pdf tool doesn't like the $ sign in the (ALEX04$DKE0) logical name.

Oswald
Volker Halle
Honored Contributor

Re: HTML2PDF for VMS?

Hayden,

and there is a DKE0:[HTMLDOC.FONT] directory with all the required font files ?

Volker.
Joseph Huber_1
Honored Contributor

Re: HTML2PDF for VMS?

On my system (VMS 7.3-1 Alpha) it looks like this:

MPIW10_HUB>sh log htmldoc_data
"HTMLDOC_DATA" = "disk$www/htmldoc/" (LNM$PROCESS_TABLE)
MPIW10_HUB>sh log disk$www
"DISK$WWW" = "AVMP01$DKA100:" (LNM$SYSTEM_TABLE)
MPIW10_HUB>sh log DECC$DISABLE_TO_VMS_LOGNAME_TRANSLATION
"DECC$DISABLE_TO_VMS_LOGNAME_TRANSLATION" = "DISABLE" (LNM$PROCESS_TABLE)
MPIW10_HUB>dir disk$www:[htmldoc]

Directory DISK$WWW:[HTMLDOC]

COPYING.TXT;1 DATA.DIR;1 FONTS.DIR;1 HTMLDOC.COM;2
HTMLDOC.EXE;1 HTMLDOC_VMS.TXT;1 README.TXT;1

Total of 7 files.
MPIW10_HUB>htmldoc -f tmp.pdf ALL.HTML
PAGES: 4
BYTES: 19848
http://www.mpp.mpg.de/~huber
Clark Hayden
Advisor

Re: HTML2PDF for VMS?

Ok. I figured out this problem. I used the unix style format you described and it worked. All I had to do was track down the junior system administrator who figured he needed some space and so deleted some of the files that I created yesterday. The files were copied back and HTMLDOC runs.

It now produces a PDF but Adobe can't read it. Is there a limit to which version of Adobe can be used to access the file? I have Adobe Reader 9.

Thanks.
Hayden.
Joseph Huber_1
Honored Contributor

Re: HTML2PDF for VMS?

Well I did not extensive tests, but my all.html in last reply is a HTML file containing some

tags, and an
    list of links in between.
    It produces a table of contentents for the

    tags, and correctly lists everything.
    XPDF on VMS and the Adobe reader on Linux have no problems with the file produced.
    So maybe some HTML elements (graphics ?) produce the errors ?
    Can You look at the acroread error ? Maybe run Adobe reader on the command-line to see errors ?

http://www.mpp.mpg.de/~huber
Clark Hayden
Advisor

Re: HTML2PDF for VMS?

I was about to post a follwo up. I see that the conversion to PDF produced the following:
ERR014: Text on page 7 too large - truncation or overlapping may occur!

Would this have anything to do with the problem being experienced by Adobe Reader?

Thanks.
Joseph Huber_1
Honored Contributor

Re: HTML2PDF for VMS?

Hayden,
since You produce the PDF on VMS, but use Adobe reader on another system (Linux, windows ?, acroread standalone, in a web-browser ?),
how do You transfer the VMS file ?
From a VMS web-server ?
Transferred to the other system by which method ?
http://www.mpp.mpg.de/~huber
Clark Hayden
Advisor

Re: HTML2PDF for VMS?

As you point out the PDF is created on VMS and is then FTP'ed as an ascii file to Windows where I use Adobe Reader 9 to access the file.
Joseph Huber_1
Honored Contributor

Re: HTML2PDF for VMS?

Try to transfer in BINARY mode.
The file produced on VMS is a stream_lf file (DIR/FULL), and transferring in ASCII mode may introduce additional line-feeds or carriage return characters (or omit those).
http://www.mpp.mpg.de/~huber
Clark Hayden
Advisor

Re: HTML2PDF for VMS?

It seems we go from one problem to the next. :)

The file transferred as a binary and it then opens in Adobe. But now the file contains blank pages and when I scroll to the nex page then the zoom jumps up to over 4000%.
Clark Hayden
Advisor

Re: HTML2PDF for VMS?

I now have the process producing a PDF file which contains HTML. The problem is that it contains the unconverted HTML for the first couple of pages. I attached the output PDF file.
Joseph Huber_1
Honored Contributor

Re: HTML2PDF for VMS?

For me it doesn't look like HTML, but more like graphics embedded in PDF.
But anyway, that's beyond my knowledge of PDF.
http://www.mpp.mpg.de/~huber