If at any given point of time there is HPLIP error as shown below for connection of network shared printers in Ubuntu and Windows !
Connecting Ubuntu systems print to a Windows-connected printer:
1. Make sure that you have smbclient installed that is
sudo apt-get install smbclient
2. Open System Settings / Printers / Add printer;
3. Choose “Windows-printer via Samba”. At this point you should be able to search through the network for printers by means of the “Browse” button. If the Browse-button is greyed out, and displays a message about “pysmbc not installed” when you hover over it, you are hit by this bug. In that case, you will need to specify the correct host name and share name (you can find these on the Windows machine). Press Next.
4. Choose HP from the list and press Next.
5. Choose the correct model name from the list.
6. Fill in a user-friendly name.
That’s it !