If you keep changing your network / connection regularly (e.g. working at office in day time and cracking your head over laptop in night at home) and you feel it difficult to keep configuring the IP again and again, here is a simple solution – Bonjour from Apple. It is a small DNS solution from Apple which comes in both flavors – Mac and Windows.
Bonjour, also known as zero-configuration networking, enables automatic discovery of computers, devices, and services on IP networks. Bonjour uses industry standard IP protocols to allow devices to automatically discover each other without the need to enter IP addresses or configure DNS servers.
Once installed, it keeps running in background and automatically does the network configuration whenever a network cable is plugged in. You don’t need to do any manual stuff anymore.