0

Im loading an Exe into my application using Assembly.LoadFile(). From that is it possible to get the Method of a particular class from that EXE. Thanks in advance .

0

2 Answers 2

3

Try:

    var assembly = Assembly.LoadFile("C:\path-to-some-app.exe");
    var desiredType = assembly.GetType("SomeNamespace.SomeClass");
    var methodInfo = desiredType.GetMethod("MethodName");
Sign up to request clarification or add additional context in comments.

Comments

1

A number of things you can do with Reflection (Including constructors, method invocation etc.) Tutorial at : http://www.csharp-examples.net/reflection-examples/

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.