You need to add the code in the button handler which is generated with the IDE as I mentioned above.
Could you please tell me what code should I add ?
I tried this :
if ( dlg.DoModal() == IDCOK )
and the compiler didn't show me any error, although, the program crashed when I pressed SLL button !