ILGenerator

Nov 23 2004 6:27 PM
Hey Guys, I have a class that can contain a formula. I dont know what this formula is going to be in advance. What I want to do is have a method called calculate in which the code of the method is modified to calculate the inputted formula. Is there anyway to generate IL code and attach it to an instance of a class. Maybe using virtual methods or delegates or something. I dont want to create an extra type because the formula can change a lot in one execution and i dont want to create all those unecessary types.