//Create a font
PdfFont font = new PdfStandardFont(PdfFontFamily.TimesRoman, 12, PdfFontStyle.Bold);
PdfFont font1 = new PdfStandardFont(PdfFontFamily.TimesRoman, 12, PdfFontStyle.Regular);
//Create a Pdf text element
PdfTextElement element1 = new PdfTextElement("Some Name:", font);
//draw text element
PdfLayoutResult result = element1.Draw(page, new System.Drawing.PointF(10, 10));
//Create a Pdf text element
PdfTextElement element2 = new PdfTextElement ("You are doing a great jop",font1);
//draw text element using PdfLayoutResult
element2.Draw(page, result.Bounds.Right + 10, result .Bounds .Y);
MemoryStream ms = new MemoryStream();
//save the document
doc.Save(ms);
Sample link:
http://www.syncfusion.com/downloads/support/forum/121589/ze/App1-1584338854
Regards,
Chinnu
//Get the client size of the page
SizeF pageSize = page.GetClientSize();
//Calculate the width and height of the text element
float width = pageSize.Width - (result.Bounds.Right + 10);
float height = pageSize.Height - result.Bounds.Y;
//draw text element
element2.Draw(page, new RectangleF(result.Bounds.Right + 10, result .Bounds .Y, width ,height));
Sample link:
http://www.syncfusion.com/downloads/support/forum/121589/ze/App1-1489447044
Regards,
Chinnu