In early 1942, Lamb's battalion and several other units were returning to Australia on board the SS Orcades, but once the ship landed at Batavia, they were ordered to defend Java against Japanese forces which had begun to move through the Dutch East Indies.
Lamb was captured as a prisoner of war and was sent to work on the Burma Railway in Thailand.