What compiler are you using?
Did you install an debugger?
Which one did you install?
What is the debugger version?
I think you need an 6 version of gdb to work with Code::Blocks.
Note: I do not use the debugger, so can not help you much more than this, but the gdb is not part of the standard MinGW installation; so, it is the common reason debugging does not work.
The next two reason gdb does not work is the "-g" compiler option is not set.
Or, the "-s" compiler option is set.
Tim S