If you want to create a control connections for a TCP or UDP port by windows 7 firewall, here is how to open ports step by step:
* Click start button --> Control Panel --> System and Security Link --> Windows Firewall --> Advanced Settings.
* In the Windows Firewall with Advanced Security Window, On the left click Inboun Rules --> On the right click New Rule link.
* On the New Inbound Rule Wizard, mark Port --> click Next --> type the ports you need to open.
For example, to open the TCP ports 21 and 80 , mark TCP and type 21,80 in the Specific local ports
* click Next --> Choose "Allow the connection" or "Allow the connection if it is secure" --> click Next --> Check or Uncheck the network type: Domain, Private, Public --> click Next --> Type a name and its description(optional) --> Click Finish.
Now the new rule takes effect immediately.