visual studio - check if the c# method is used in the project -


is there way or plugin see if method (get list of methods) in project not been used?

i can list of methods in project using . how check if method being used in project

type.getmethods() 

this hard find in large project. can try several approaches.

  1. right click on function -> find references. these references death code. check references each. , again after find out if used or not.

  2. search method name text , check occurrences. repeat callee if needed.

  3. another simple approach put breakpoint inside , run application , go throw scenarios. hardly go throw scenarios. can cover part of it.

sometime can tricky if reflection used. such method called reflection , hardly find out reference search.

no approach 100%. can try combination of them.


Comments

Popular posts from this blog

javascript - Chart.js (Radar Chart) different scaleLineColor for each scaleLine -

apache - Error with PHP mail(): Multiple or malformed newlines found in additional_header -

java - Android – MapFragment overlay button shadow, just like MyLocation button -