Hi,
You may want to have a look at method GET_INTERACTION_RECORD of class CL_ICCMP_CUCOIREC_IMPL.
This is where the interaction record gets created on confirming the identification of a BP.
You will notice this part :
* set anchor objects into document flow of interaction record * - indentifies business transaction as interaction record * (has to be called before set_interaction) me->set_anchor( ir_btorder = lr_irec ).
The anchor is set here. You may want to reproduce that into your development.
Hope this helps.
Best regards.
Sylvain