Hi,
I'm new here so sorry for anny mistakes I make.
I've been looking/trying for 2 days to find a solution for my problem. Please help me.
I have mixed PDF-Sharp and MigraDoc to create an offer Printout / PDF (Version 1.31).
Thus far everything works fine, but I have a problem with the description text I want to show. The string is long and would print out over sevral lines, but the programming only makes one line, which gets cut of at the page edge.
following a code snippit.
Code:
Document MigDoc = new Document();
Section sec = MigDoc.AddSection();
// Create a renderer and prepare (=layout) the document
MigraDoc.Rendering.DocumentRenderer docRenderer = new MigraDoc.Rendering.DocumentRenderer(MigDoc);
docRenderer.PrepareDocument();
Paragraph paraArt;
paraArt = sec.AddParagraph();
paraArt.Format.Font.Name = "Arial";
paraArt.Format.Font.Size = 9;
paraArt.Format.Font.Color = MigraDoc.DocumentObjectModel.Colors.Black;
paraArt.AddText(Description);
docRenderer.RenderObject(XGfx, StartP.X+35, StartP.Y + 43, 350, paraArt);
As mentioned I want the text to break line and fit in a width of 350 units. If I add boarders to the paragraph then the boarder does actually stop at the desired width
attached are three pictures. one shows the amount of text I want shown. The second shows the output PDF I get and the second with boarders.
One thing that gets me is I did have it working, but after a simple adjustment in the header (additional Text lines) it switched to one line only.
Is there a command for this, which I haven't found or not understood yet?
Thank you for any help.