Detect pincode

Hi,
Got Vera lite connected to a dsc 1864 wirh envisalink 3.
Everything is working great.

I want to be able to send an email if a certain pincode arms and disarms the dsc.
Is this possible and if thats the case, how do i do it.

Best regards
Andreas