PDFsharp & MigraDoc Foundation

PDFsharp - A .NET library for processing PDF & MigraDoc Foundation - Creating documents on the fly
It is currently Thu Mar 28, 2024 11:25 am

All times are UTC


Forum rules


Please read this before posting on this forum: Forum Rules



Post new topic Reply to topic  [ 1 post ] 
Author Message
PostPosted: Thu Jul 05, 2007 9:50 am 
Offline

Joined: Thu Jul 05, 2007 8:41 am
Posts: 1
Hi ,

Thanks for making a useful tool like PDFSharp.

I am new to PDFsharp and have been using it for last 10-15 days.

In one of my paragraph the string contents are from DB. These string values are to be shown in bold. I have used the following code to generate the pararaph in my PDF.

string strPara;
strPara = "Please submit this form, along with your resume, to the address below. You do not need to include anything else, because you have selected the " + strDeadline_Title + ", you must arrive at our office no later than " + Deadline_Date + " ! This is not a postmark deadline.";

XTextFormatter oPara = new XTextFormatter(gfx);
oPara.Alignment = XParagraphAlignment.Justify;
oPara.DrawString(strPara, font, XBrushes.Black, new XRect(new XPoint(leftMargin, currentY - 10), new XSize(pageWidth - (leftMargin + rightMargin), 40)));

The output of the above code is working fine. But now I need to show the value strDeadline_Title and Deadline_Date in BOLD in the PDF.

Is there anyway that will make these 2 values appear bold in the paragraph and my paragraph appear Justified aligned.

Note : the values from does not have fixed width.

Please reply soon , it urgent .. :)
Thanks
Kunal


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ] 

All times are UTC


Who is online

Users browsing this forum: Google [Bot] and 118 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Privacy Policy, Data Protection Declaration, Impressum
Powered by phpBB® Forum Software © phpBB Group