In my scenario. i am sending file which contain multiple header with multiple item lines. in item line. in mapping counter to Assigned to item_number. at every context change at header i need to reset the counter to 10. for this i have to write Adv UFD.
plz can any one provide Logic or UFD.
thanks in Advance,
when I understand your problem correct you won't have to write a UDF as a standard function exists which should cover your problem: index (within category statistic).
Initial Value: 10
Count indices in: context
You'll have to ensure that you give the input queue with correct context changes. In your case it should look like that:
item_data (set context to Header_data) --> Standard Function index --> output field in IDoc structure.
Input queue of item_data should look like that your mapping editor: