Hey Cassp,
With Cakewalk open, click on Options, click on Project, click on the Midi Out tab, and verify that the Zero Controllers When Play Stops box is checked.
Here's a cut & paste from the Help files:
Zero Controllers When Play Stops...if you check this box, Cakewalk zeroes the pitch wheel, the sustain pedal controller, and the modulation wheel controller on all 16 MIDI channels. It also sends a “zero all continuous controllers” MIDI message which turns off other continuous controllers on newer synthesizers. If you experience frequent stuck notes when playback stops, try checking this option.
-mike