You don't need a no-ip, unless your IP address changes frequently.
Make sure your server is running when you're checking if the port is open, and that it does say open (still).
When you're on the same computer as the server, you should set the client's IP to localhost, or 127.0.0.1
When it's on a different computer, you should set it to your ip address seen here or your no-ip if you're using that.
If your other computer is still having an issue connecting to the server, try setting the IP address in the client to the same one you used to portforward with (your local network IP).
Thanks for your reply.
I set the 'server = ' to 127.0.0.1 and I'm able to login on my Hosting PC.
Sorry this may sound stupid, but how can I make it so the 2 IP Addresses are in the code?
As if I leave it at 127.0.0.1 and release the client to my friend he won't be able to get online, will he?
How can I make it so I can get on my computer and then he can get online at the same time?
Sorry if this sounds a bit confusing.
1) Make two client.jar files. One with it set to localhost (I'd name it like clientlocal.jar) and one set to your IP from the site mentioned earlier.
You'd give people the second jar file, while keeping the first one for yourself.
This is the easier of the two options, hence why it's listed first.
2) Add a new button onto the login screen, or a string to change the IP, or similar method.
This is a bit harder, and how to do it can vary from client to client.
But generally, you'd copy one of the existing buttons and replace the text, and give it a new location.
Then you'd make a boolean that would be set true/false by clicking the button. When true, the connecting ip would be localhost, when false, it wouldn't.
Or you'd display the server IP in a string (Copy the "Username" or "Password" field).
Then whenever the player hits login the client would use whatever was displayed as the login ip.