I've always done the AoO before the actuall event that triggered the AoO occurs. For example:
PC: I attempt to sunder his sword!
DM: Ok, since you don't have Sunder, he gets an AoO against you
PC: Oh, ok.
If the AoO comes AFTER the sunder in this case, then its hard to make the AoO.