Check out an MAudio MIDIsport. They've been around for years and the drivers are pretty stable. Connects via USB to your puter.
From the question, I'm guessing the OP is probably a noob, in which case we can skip all of the complications (that he may well not understand anyhow) and offer up this simple and inexpensive solution...
Buy M-Audio USB Uno 1X1 MIDI Interface | MIDI Interfaces | Musician's Friend
This is a better idea. I have two 4x4s and a MOTU 5x5. I can reach a MIDI device to my PC from anywhere in the room. I use MIDI-OX to connect physical and virtual MIDI ports.
The only problem I've had with them is that the US-428 control surface doesn't play nice with other USB devices on the system.