Enchantments?, Encantments?

How do you work enchantments to know if a boundary line has been gone through?