Only 63 lines are getting fit in one page

Posted by: mayur.purandare on 17 January 2019, 7:40 pm EST

    • Post Options:
    • Link

    Posted 17 January 2019, 7:40 pm EST

    I have a requirement where each page contains 70 lines of data.

    C1.wpf.pdf :

    When I am using DrawString() to write data to page only 63 line are coming on page with 3 dots(…) at of end 63 line no.

    pdf.DrawString(onePageString, font, Colors.Black, new Point(20, 20));

    C1. Pdf :

    But When I am using DrawString() to write data to page all lines are comin properly means 70 lines gets added properly per page.

    pdf.DrawString(onePageString, font, System.Drawing.Color.Black, new PointF(20, 20));

    Why two libraries are giving the different results ?

  • Posted 17 January 2019, 8:21 pm EST

    With Respect to above query I have uploaded two file generated using two libraries.

  • Posted 17 January 2019, 8:30 pm EST

  • Posted 20 January 2019, 11:27 pm EST

    Hello,

    I am unable to reproduce the issue at our end. Please refer to the attached application.

    Could you please either modify the attached application or provide your own stripped down project so that I can try reproducing the same behavior at my end and assist you further accordingly?

    Thanks.

    WpfApp3.zip

  • Posted 10 February 2019, 6:00 pm EST

    Hello,

    I have modified your code little bit and Uploaded same. Issue is reproducible on same.

    Also please let me know the logic behind 8 * (i + 1) for Y Coordinate. Why 8 is taken as base.

  • Posted 10 February 2019, 7:10 pm EST

  • Posted 10 February 2019, 9:02 pm EST

    IF I use same code in C1.pdf, Output is coming proper.

    Please find attachment for same code.

    WpfApp3C1Pdf.zip

  • Posted 12 February 2019, 10:40 pm EST

    Hi,

    Thanks for your reply.

    Please let us know, till when we can expect reply from development team?

    Our project is in peak phase, that is why we need this on urgent basis.

  • Posted 12 February 2019, 11:09 pm EST

    Hi,

    The issue has been fixed. I’ll let you know when we have an ETA for the release of this fix.

    Thanks.

  • Posted 18 February 2019, 10:40 pm EST

    Hi,

    Is there any update on this.

    Thanks.

  • Posted 19 February 2019, 5:17 pm EST

    Hi,

    Thanks for your modified sample. We can replicate the issue, and we’ve escalated it to the development team [Internal Tracking ID: 366575]. We’ll let you know as soon as we have an update from them.

    As for why ‘8’ is taken as the base:

    In the sample this line is used

    ds.DrawString(text, new Font("MS Gothic", 8), Color.Black, new Point(20, 8 * (i + 1)));
    

    Here, the font size is 8. So, to draw the line at the correct Y coordinate the height of the font is used as the base of the offset.

    Regards,

    Jitender

  • Posted 19 February 2019, 5:59 pm EST

    Hello,

    We’ve asked the developers to provide an update on this. We’ll update this thread when we get any information from them.

    Thanks.

  • Posted 20 February 2019, 2:34 pm EST

    Hi,

    Currently the ETA for this fix is end of March.

  • Posted 21 February 2019, 8:59 pm EST

    Ok.

    Thanks for the information.

    When we will get this solution in our product (Component one). Do we need to install it again or what is the procedure.

    Thanks.

  • Posted 21 February 2019, 10:09 pm EST

    Hi,

    All updates are delivered through C1Live. You can see how to use it in this blog post:

    https://www.grapecity.com/en/blogs/update-your-controls-in-one-click-using-the-c1live-utility

    The ETA, as already stated, is end of March.

  • Posted 18 March 2019, 8:45 pm EST

    Hi,

    The fixed build is now available.

    You can update your installation using C1Live.

    You can also refer to this link for C1Live: https://www.grapecity.com/en/blogs/update-your-controls-in-one-click-using-the-c1live-utility

    Thanks,

    Jitender

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels