Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
这就是我要搜索的内容:
[assembly: AssemblyFileVersion("4.0.10.121017")]
数字应该可以
我已经写了这个但是那不起作用
@"\[assembly: AssemblyFileVersion\(\""(\d{1}).(\d{1}).(\d{2}).(\d{6})""\)\]"
[1-9]\d{0,2}\.(?:[1-9]|10)\.[1-9]\d{0,3}\.\d{6}
编辑(基于问题更新):
[1-9]\d{0,2}\.(?:\d|10)\.[1-9]\d{0,3}\.\d{6}
只需将您的需求转换为正则表达式:
\[assembly: AssemblyFileVersion\(\"\d{1,3}\.\d{1,2}\.\d{1,4}\.\d{6}\"\)\]