7037 Error with key in custom index

Advantage Error Guide

Problem: Attempted to add a key for the current record into the custom index and the key already exists.

Solution: You cannot add a key to a custom index more than once for a single record. Do not call the AX_KeyAdd() function if a key already exists in the custom index for the current record.