Title: Message

Dear itext,

I got teh following error when creating an font:

java.lang.NoClassDefFoundError: com/lowagie/text/pdf/PdfEncodings
 at com.lowagie.text.pdf.BaseFont.createFont(Unknown Source)
 at com.lowagie.text.pdf.BaseFont.createFont(Unknown Source)
 at com.lowagie.text.pdf.DefaultFontMapper.awtToPdf(Unknown Source)

The code behind is:

    java.awt.Font lFontAwt = new java.awt.Font("Courier", java.awt.Font.PLAIN, 1);
    DefaultFontMapper lFontMapper = new DefaultFontMapper();
    try
    {
             BaseFont lBaseFont = lFontMapper.awtToPdf(lFontAwt);
    }
    catch(Exception ex)
    {
                 ex.printStackTrace();
    }

I've also tried to use the lowagie way of creating a font:

BaseFont bfVerdana = BaseFont.createFont(lFontName, BaseFont.CP1252, BaseFont.EMBEDDED);
Font mFontVerdana = new com.lowagie.text.Font(bfVerdana, 8, com.lowagie.text.Font.NORMAL);

This will raise the same error.

When I do not define a font the applicatiojn will crash with the same error when the document.add(new Paragraph("A Text")); is excuted.

is there somebody who can help me?

The version a use is iText 1.02b

Tanks in advance for helping.
greetings

Wijnand Beke

Software Engineer

IQuality

direct +31 (0)24 3719770

e-mail [EMAIL PROTECTED]

website http://www.iquality.nl

 

Reply via email to