Wednesday, May 16, 2012 4:24 AM
Hi.....I used richtextbox to edit result and send result to word document.....I want display the result heading and result.. I used alignment for heading and result. Alignment property is applied to heading, but this property is not applied to result. Result is being started at left side just after 10px of the starting page.. I need to increase the indent of the paragraph of the result...I used code to this purpose at printing report page...I display code below...
first paragraph for result heading, second paragraph for result.... I need increase paragraph indent of the result.
object oRng = objWordDocumentForXray.Bookmarks.get_Item(ref oEndOfDoc).Range;
oPara1 = objWordDocumentForXray.Content.Paragraphs.Add(ref oRng);
oPara1.Range.Text = sTestName;
oPara1.Alignment = WdParagraphAlignment.wdAlignParagraphCenter;
oPara1.Format.SpaceAfter = 6;
object oRng2 = objWordDocumentForXray.Bookmarks.get_Item(ref oEndOfDoc).Range;
oPara2 = objWordDocumentForXray.Content.Paragraphs.Add(ref oRng2);
//oPara2.Alignment = WdParagraphAlignment.wdAlignParagraphCenter;
oPara2.Format.SpaceAfter = 6;
oPara2.Range.ParagraphFormat.LeftIndent = objWordApplicationForXray.InchesToPoints(3F);
Wednesday, May 16, 2012 6:17 AM
Seems this is achievable as below links says :
I am using ASPOSE component to do similar kind of functionalities which may help you.