RicardoE 11 Junior Poster in Training

Hello All,

I'm currently developing an application to Map HTML/Javascript/CSS to C# Objects and code,
and I have come to a point where I get to translate all de Javascript Code to C# and the HTML to C# GUI for example:

<Input type="Button" value="Button1" class="btn_java" onClick="javascript:MyFunction()" />

I had no problem on dinamically create the button and apply the style, the problems comes when I had a string with the C# translated from javascript code, and I want to run it for that button, adding it to a Clicked eventHandler

button1.Click += new System.EventHandler(this.button1_Click);

Then I need, to find some way to convert the string code into executable code

private void button1_Click(object sender, EventArgs e){
           my_translated_string();
}

I think the answer is to use the Compiler class but I need some simple examples on how to do this.

thanks in advance for your help