some modification given below
1.atof() takes one argument.
2.use double instead of float since your data seems to be of double size
3.remove comma with just one CString funation call Remove().
i hope following may help you
CString str="99,520.255";
str.Remove(',');
double val;
val=atof(str);