how do you disable the 'X' close button then?

I tried

pSysMenu->EnableMenuItem (SC_CLOSE, MF_BYCOMMAND|MF_DISABLED);

but all it does it gray out the 'X' close button but not removing it...