I am working on C# 3.5 winforms project.
I want to execute some code dynamically, which is in a string variable.
the code, I want to execute is something like this :
(GetSetting("MYSETT1") == 1? "OK" : "Cancel")
I want to use methods which are existed in my project and by using them I want to perform some task.
Is it possible dynamically ?
You can dynamically compile your code and execute.
This links may be helpful:
Using the CodeDOM
Dynamically executing code in .Net