Get id from active field

Can I ask why do you need to store the ID?