ritika purwar

ritika purwar

  • NA
  • 0
  • 21.6k

page break

Jan 29 2015 4:56 AM
private void InsertPagebreak()
{
{
IHTMLDocument2 htmldocument = editorWebBrowser.Document.DomDocument as IHTMLDocument2;
IHTMLSelectionObject currentSelection = htmldocument.selection;
if (currentSelection != null)
{
IHTMLTxtRange range = currentSelection.createRange() as IHTMLTxtRange;
if (range != null)
{
string newhtml = "<div style='page-break-after: always'><span style='display: none;'>&nbsp;</span></div><hr>";
newhtml += range.htmlText;
newhtml += " ";
range.pasteHTML(newhtml);
}
}
}
}
this is for insert page break... i want for delete page break...??