开发者

.NET Reflector - Reflexil, Change private to public

I have an assembly loaded into .NET reflector and I have the reflexil addin. I found a method in the assembly but it's private. Copying the whole method to my code is too much work because it uses many other m开发者_开发知识库ethods in the assembly. I just want to change

private void Check(string Proxy, int Port)

to

public void Check(string Proxy, int Port)

So I can use it in my code. Does anybody know how to change it and how to save the fixed assembly after that?

Kirk


Instead of re-writing the assembly, consider using Reflection from your code to invoke the private method dynamically, see:

How do I use reflection to invoke a private method?

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜