Lock Code plus some messing around