I love ReSharper for C#, but kept having problems with it generating an warning about “inconsistent naming” on every event handler generated by Microsoft Visual Studio 2010. I kept thinking that there must be an easy way to tell ResSarper that ”SomeObject_SomeEventHandler” is a valid name for a method.
I finally came across the answer on a thread on their forum, and it is really easy to fix.
In Visual Studio 2010, you:
- go To Resharper -> Options -> Languages -> Common -> Naming Style
- Click “Advanced Settings”
- On the dialog you will find “Event subscriptions on fields“. Change the value to “$object$_$event$” and it should work.