I want to make a simple program. But I don;t know how.

I want to make an exe generator.
In this; there will be dialog with one edit box and one button (labeled "generate exe"). when user will click on "generate exe" button. An exe will be generated; when user will run the generated exe it will show a message box which will contain the same message as user entered in the edit box before generating exe.

I guess for this I need to generate the code(or cpp file) at run time then I need to compile it at runtime. But I don't know how.