Assuming you are trying to connect to LAN on the Java version:
Make sure that both computers are setup to the same network you are using. Make sure a firewall is not blocking the client from connecting to the host, which would be the host of the server. Open to LAN and see if it can work. It's actually straightforward like that... I don't see any other reason why it shouldn't work if the firewall is not blocking the client.
Too add to this, some antivirus software is a bit overzealous when it comes to LAN. Check AV specific settings as well.