To use Dynamic Lock, your PC or laptop has to be connected to your phone via Bluetooth, the only benefit of which is whenever you take your phone away from the laptop or PC. Then your laptop or PC will be automatically locked.
Click on the Start Menu, go to Settings, click on Accounts.
Click on the Sign-in option to turn on Dynamic Lock.
Pair your phone and desktop via BlueTooth.