Regex for MS Word for detecting subtitle

不打扰是莪最后的温柔 提交于 2020-01-03 07:02:48

问题


I have a MS Word Documents with its subtitle all in font-size 18px and bold. I want to find them all and replace them with something else. There I use Ctrl+H, enabling wldcards, chossing the font style (fontsize and bold), and use the regex (*{1,}). However, this regex would find occurrences for every single character. How can I make every whole subtitle as a single occurence? Thanks


回答1:


Use a Word wildcard Find/Replace, where:

Find = ([!^13]@)^13
Replace = Before Text \1 After text^p

and you specify the font attributes as part of the Find parameters. No code required, though you could use a macro if you really want to - the macro recorder will replicate the F/R parameters.



来源:https://stackoverflow.com/questions/58569120/regex-for-ms-word-for-detecting-subtitle

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!