Flash Media Server Rejecting Connections?

I was following the simple tutorial at http://www.hiteshagrawal.com/flash/f…er-application and I found that my RTMP will reject the connection and then close it giving me this:

NetConnection.Connect.Rejected
NetConnection.Connect.Closed

That happens why trying to connect to localhost, can anyone help me?