Visual Studio:仅搜索未注释的代码 [英] Visual Studio : Search Uncommented Code only

查看:147
本文介绍了Visual Studio:仅搜索未注释的代码的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有什么方法可以将查找/搜索"限制为仅未注释的行吗?
(也许使用正则表达式会是一个很好的线索)

Is there any way to restrict the Find/Search to uncommented lines only ?
(Maybe using regex would be a good lead)

推荐答案

让我们说,如果您需要搜索所有未注释的文本"VPEntity",请在选择使用RegEx"后尝试在文件中查找以下正则表达式选项

Lets say, if you need to search all occurrences of an uncommented text "VPEntity" then try using the following regular expression in Find in files after selecting the Use RegEx option

^((?!//|/\*).)*VPEntity

希望它对您有用

这篇关于Visual Studio:仅搜索未注释的代码的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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