For Windows you can switch between multiple print ports to print. Check which print port is available. The following example is for Windows 10.
When you select the wrong port, you cannot print. Select the correct port depending on your environment. For example, when you select USBXXX port if you want to print through the network, you won't be able to print.
Click start, and then select Devices and Printers.
Right-click the printer icon, and then click Printer Properties.
Select the Ports tab to check which print port is selected.
Print ports selected in the port column are available. You can check the port type from Description.