Is there an easy way to force TCP/IP ports in Windows XP.

I open a dos window and run netstat
c:\netstat

Which gives me a list of open ports on my computer and who is connected to them. Is there a simply code or script that can be would allow me to close open ports?

regards,
homerj31