Hi,
Thanks for your hot fix and unfortunately it looks like not working.please find the attached templates.
And also when i am trying to use the replaceText(String source,String dest, TextProperties textProperties) method is throwing an exception
ava.io.IOException: InputStream cannot be null
at com.aspose.pdf.kit.gt.a(Unknown Source)
at com.aspose.pdf.kit.PdfContentEditor.replaceText(Unknown Source)
at com.aspose.pdf.kit.PdfContentEditor.replaceText(Unknown Source)
at com.yelladworks.spec.service.impl.GenerateSpecImpl.generatePrintSpec(GenerateSpecImpl.java:158)
Also the TestProperties.setColor method is also throwing some exceptions like Color is out of range for Reed…
what we exactly want is that anyway color is maintaing with the current version 3.1 we want is we will pass the font name along with the size so that it replaces the text exactly with same font what is there in the template.
Also why Aspose is not able to maintain the font while replacing the text ?
FYI…
i am trying the following code
String fontName=“AvantGarde-Bold”
int fontSize=12;
TextProperties textProperties = new TextProperties();
textProperties.setFontFamily(fontName);
textProperties.setTextSize(fontSize);
editor.replaceText(text1, “Arijit sarkar”, textProperties);
My sample font name would be like
AvantGarde-Bold, Eurostile-ExtendedTwo, AvantGarde-Book, AvantGarde-CondDemi…
I guess its not taking the style after -
Thanks,
Arijit