Text getting cut off when exporting to PDF
Posted: Fri Mar 07, 2014 5:15 pm
I am using Stimulsoft.Reports.Web.2013.1 and need to create a report that has a page for each record returned from a database query. On each page I want to show a table that has a row for each field and two columns: the left column showing the field name (e.g., "Name") and the right column showing the field value (e.g., Michael Jackson). Some of the values can be several sentences long and can wrap.
I have created such a report by using a DataBand and then in the DataBand adding appropriately sized TextBoxes for the labels in the left and values in the right. This works swimmingly when viewing the report from a web page. I've attached an image showing how this works as expected. Note that I've blurred out the field values, but you can see the field value for the Comment / Issue is several sentences long and the text wraps as desired.
The problem is that when I export this to PDF using the Save --> PDF feature from the report viewer, the PDF text does not wrap. I've also included a screenshot of the same row when exported to PDF. Note how the Comment / Issue row does not grow - the text gets cut off.
I've tried setting the Can Grow and Word Wrap properties of the TextBox that holds the value of the Comment / Issue (and of the TextBox that holds the text "Comment / Issue") but it only increases the height of the field value and not of the label, which results in a "broken border" (see screenshot). The upside of this is that the exported PDF doesn't cut off the text, but it too suffers from the "broken border."
I surmise the problem is because I'm using TextBoxes rather than a table, so the label "cell" doesn't necessarily align with the value 'cell," but I was unable to determine how to create a table for a single database record with rows for each field and with two columns for the name/value of each field.
Any help is much appreciated.
Thanks
I have created such a report by using a DataBand and then in the DataBand adding appropriately sized TextBoxes for the labels in the left and values in the right. This works swimmingly when viewing the report from a web page. I've attached an image showing how this works as expected. Note that I've blurred out the field values, but you can see the field value for the Comment / Issue is several sentences long and the text wraps as desired.
The problem is that when I export this to PDF using the Save --> PDF feature from the report viewer, the PDF text does not wrap. I've also included a screenshot of the same row when exported to PDF. Note how the Comment / Issue row does not grow - the text gets cut off.
I've tried setting the Can Grow and Word Wrap properties of the TextBox that holds the value of the Comment / Issue (and of the TextBox that holds the text "Comment / Issue") but it only increases the height of the field value and not of the label, which results in a "broken border" (see screenshot). The upside of this is that the exported PDF doesn't cut off the text, but it too suffers from the "broken border."
I surmise the problem is because I'm using TextBoxes rather than a table, so the label "cell" doesn't necessarily align with the value 'cell," but I was unable to determine how to create a table for a single database record with rows for each field and with two columns for the name/value of each field.
Any help is much appreciated.
Thanks