Welcome Guest Search | Active Topics | Sign In | Register

Get a Substring error when saving a PDF with merge fields Options
Dale
Posted: Saturday, October 8, 2022 6:10:46 PM
Rank: Newbie
Groups: Member

Joined: 4/11/2018
Posts: 3
When a PDF text field uses the "Comb Of Characters" property the following error is returned when saving a PDF document after adding the values:

Index and length must refer to a location within the string.\r\nParameter name: length","StackTrace":" at System.String.Substring(Int32 startIndex, Int32 length)\r\n at EO.Internal.tbji.iaxb(String jk, Boolean jl)\r\n at EO.Internal.tbji.iaxa()\r\n at EO.Internal.tbji.iawu()\r\n at EO.Pdf.PdfField.gehy()\r\n at EO.Pdf.PdfField.jegk()\r\n at EO.Internal.tbjn.jegk()\r\n at EO.Pdf.PdfDocument.omeq()\r\n at EO.Pdf.PdfDocument.Save(Stream stream)\r\n at

This is happening in the latest version 22.2.49.0.
It doesn't happen in an older version from 2018 that I have been able to test with: 18.1.31.0
eo_support
Posted: Monday, October 10, 2022 10:51:52 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,103
Hi,

Can you send the PDF file in question to us so that we can debug it here? See here for more info:

https://www.essentialobjects.com/forum/test_project.aspx

Thanks!
Dale
Posted: Monday, October 10, 2022 3:07:24 PM
Rank: Newbie
Groups: Member

Joined: 4/11/2018
Posts: 3
Hi, I've sent a simple PDF with just one form field. The error occurs when calling Save and I'm using a MemoryStream if that makes any difference:
MemoryStream mStream = new MemoryStream();
doc.Save(mStream);
eo_support
Posted: Tuesday, October 11, 2022 1:59:06 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,103
Thanks for the test file. We were able to find out the root cause. This will be fixed in our next build and we will reply here again as soon as the new build is available.
eo_support
Posted: Friday, October 21, 2022 2:24:06 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,103
Hi,

This is just to let you know that we have posted a new build that should resolve this issue. You can download the new build from our download page. Please take a look and let us know how it goes.

Thanks!
Dale
Posted: Sunday, October 23, 2022 6:38:58 PM
Rank: Newbie
Groups: Member

Joined: 4/11/2018
Posts: 3
Hi, I've updated and works now, thanks!
eo_support
Posted: Monday, October 24, 2022 9:42:53 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,103
Great. Thanks for confirming the fix!


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.