.NET reflection emit – what am I doing wrong in writing this method in MSIL?

Advertisements I am trying to dynamically create a delegate that returns a list of the values of all properties defined on an object, using reflection emit in C#. I have started with the examples given here: https://learn.microsoft.com/en-us/previous-versions/dotnet/netframework-4.0/exczf7b9(v=vs.100) Then, I have used LinqPad to view the IL for the code I want to emit. E.g., for… Read More .NET reflection emit – what am I doing wrong in writing this method in MSIL?

Why cannot I create a dynamic delegate which has more than one argument using .NET EMIT

Advertisements There are some definations: public class Message { public SayType Say(string name) { Console.Write("Hello," + name ); return SayType.Name; } public SayType Say(string name,string haha) { Console.Write("Hello," + name ); return SayType.Name; } } public enum SayType { Name } And I want to create two dynamic of the two function in class Message.… Read More Why cannot I create a dynamic delegate which has more than one argument using .NET EMIT