My MIDI timing is off, but only when recording.

Just like I said above. My timing is fine until I record into my PC. Is it a processing problem or what? I am running my sequencer on the same PC I'm recording into. If that's the problem is there a fix for it? Please help me, I'm going to go softly cry myself to sleep now. Bye.