Hi All,
This is my first post in here...
Iam working on a report editor based on wpf flow document, I have been able to display Text reports on Flow Document Scroll Viewer also i am able to annotate the content using Annotation Service
But now Iam intending to annotate that flow document content in a manner that only the alternate lines of text (like 1st,3rd,5th...) gets colored while the other (2nd,4th,6th...) ones remain as it is.
Iam not being able to get to the individual lines of text in flow document...once i achieve this, coloring will not be a big problem as WPF provides Annotation Service.
Please provide any help in this regard.....
My initial code ia as follows:
namespace TextOnFlowDoc
{
/// <summary>
/// Interaction logic for Page1.xaml
/// </summary>
public partial class Page1 : Page
{
public Page1()
{
InitializeComponent();
Paragraph paragraph = new Paragraph();
paragraph.Inlines.Add(System.IO.File.ReadAllText(@"C:\Lis.txt"));
paragraph.FontFamily = new FontFamily("CourierNew");
FlowDocument document = new FlowDocument(paragraph);
// FlowDocumentReader rdr = new FlowDocumentReader();
FlowDocScl.Document = document;
}
}
}