本文介绍了如何删除Msword中从特定范围到文本结尾的文本。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述





我正在通过C#应用程序着色MSword Text的应用程序,因为我需要删除从特定范围到文档末尾的文本。我知道我想要删除startindex的范围,但是如何给出文档的结尾我没有结束索引。有没有办法从特定范围到文档结尾删除,而不是手动给出结束索引,如下所示。



 Word.Range range = currentDocument.Range(paragraphPosition1(我知道),End ofdocument(?)); 
range.Delete();
解决方案

Hi,

I am working an application of coloring MSword Text through C# application as apart of requirement i have to Delete the text from specific range to end of document .I know the range from which i wanted to remove the startindex, but how to give end of the document i dont have end index.is there any way to delete from specific range to end of document with out giving end index manually like below.

Word.Range range = currentDocument.Range(paragraphPosition1(I know), End ofdocument(?) );
range.Delete();
解决方案


这篇关于如何删除Msword中从特定范围到文本结尾的文本。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

05-28 05:45
查看更多