Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to avoid garbage values written into a pdf file using itext?

 
Pratik Shirsat
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
HI,
I m writing into a pdf file from my application using a itext api.A remark field from the application is first populated by the client which is stored in the database after saving and afterwards fetched from database and written into a pdf file.What client does is...he copies the data from a word file and copies it in the remark filed in the application before saving it.This data in MS Word contains bullets and numbers.So When this data is stored in the database ,it stores some garbage values into the database which I suppose represent the bullets.After generating the PDF the same garbage values appear in PDF.

the data written into PDF looks somewhat like this:
"Following are the actions taken by MCG
Bangalore:
Branch has marked debit freeze
in the Effone Technologies account no.

"


So..is there any way by which these garbage values can be avoided???
Please help me out as this is really urgent....

Thanks
 
Tim McGuire
Ranch Hand
Posts: 820
IntelliJ IDE Tomcat Server VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Best to scrub the MS Word garbage at its source before it gets into the database.

Either client-side with a script like the one described here:
http://jhy.io/tools/convert-word-to-plain-text

or on the server-side before saving it to DB.

 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic