正则表达式搜索模式不包括一个文件

时间:2021-06-13 16:49:54

in Visial Studio 2010 I want to use a regex pattern in the built-in Find and Replace Dialog, and I want to search in that type of files *.cshtml, *.cs, *.js but except e.g. myController.cs file. How to do it ?

在Visial Studio 2010中,我想在内置的查找和替换对话框中使用正则表达式模式,我想搜索该类型的文件* .cshtml,*。cs,* .js,但例如myController.cs文件。怎么做 ?

1 个解决方案

#1


1  

Something like this?

像这样的东西?

\b^(?!myController\.cs).+\.(cs(html)?|js)$\b

#1


1  

Something like this?

像这样的东西?

\b^(?!myController\.cs).+\.(cs(html)?|js)$\b