For a printer with a a network card and it's own IPADDRESS This is what I believe you have (based on your error message).
1. Install the printer as if it was a locally attached printer (LPT1 for example)
2. Right click on the printer and select printer properties.
3. On the Ports tab, click 'add port'
4. Select a standard TCP/IP port and choose 'New Port'
5. The port wizard opens
6. Type in the printer network name (or ipaddress) [NOTE: Ensure that the printer is turned on!)
7. Windows will now detect the printer on the NEW port you just created. Accept everything and ok -out.
A printer attached to another PC
1. Ensure that the printer is shared on the host pc and that permissions are granted in both sharing and security.
2. Press WINDOWS+E to open windows explorer
3. Navigate to the host PC across the network (e.g \\192.168.1.5 or \\mycomputername)
4. The printers icon should be displayed in explorer.
5. Right click and select 'connect'