检测Docx文件中的换行符? [英] detect line break in Docx file?

查看:323
本文介绍了检测Docx文件中的换行符?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

将docx文件转换为txt格式。哪个检测到docx文件中的换行符和txt文件中的相同内容?怎么办?

Convert the docx file into txt format.Which detect the line break in docx file and same write in txt file?HOW?

推荐答案

我相信换行符是< w:br xmlns:w =#unknown/> 标记,您可以使用 Environment.NewLine 在文本文件中写一行。



请注意,纯文本文件的行为方式与Word文件不同,因此您无法在格式化方面做太多工作。



以下CodeProject文章也可以帮助显示Word WPF中的文件 [ ^ ]和在Word文档中查找文本 [ ^ ]
I believe the linebreak is the <w:br xmlns:w="#unknown" /> tag and you can use Environment.NewLine to write a line to the text file.

Note that plain text files don't behave in the same way as Word files so you can't do much in the way of formatting.

The following CodeProject articles may also help Show Word File in WPF[^] and Find Text in Word Documents[^]

这篇关于检测Docx文件中的换行符?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆