Recently, I just coded a F46 equipped with BMW ANTI-THEFT ALARM WITH REMOTE CONTROL (VO code 302). Right after I finished with the coding, my pal locked the car and the car alarm was triggered. This surprises me as I didn't expect the alarm to sound when the car is lock and suspect that the coding has screwed it up. I went on to revert back all the changes but the alarm still goes off once the car is locked.
After fumbling for an hour, it was discovered that the OBD cable has to be DETACHED from the socket before the car can lock without triggering the alarm. This is a new lesson that I learned today and I hope you will find it useful to know!