c# - FlowDocument page load based on the next page button click -


i loading huge document more 25mb flowdocument. , fine, it's taking more cpu or long time during initialization load entire data flowdocument. instead of there way load page dynamically based on next page click in bottom of flowdocument control.

sample code of flow document.

<scrollviewer horizontalalignment="stretch">             <groupbox>                 <groupbox.header>                     <textblock text="standard output"></textblock>                 </groupbox.header>                  <flowdocument name="flowdocument" columnwidth="999999" background="transparent" iscolumnwidthflexible="true" >                      <paragraph name="para" background="transparent" textalignment="justify" keeptogether="true">                     </paragraph>                  </flowdocument>             </groupbox>          </scrollviewer> 

i assigning data in code behind file.

code populate flowdocument in code behind file.

para.inlines.add(readdocument());  public void readdocument() {    texttodisplay = file.readalltext(@"c:\samplelog.txt"); } 


Comments

Popular posts from this blog

How to use SUM() in MySQL for calculated values -

ios - IBOutlet for image button not correctly referencing button after recreating outlet -

java - AEM: 403 Forbidden occurs when call a Post servlet -