Question: when did jack sparrow get cursed?
Answer: Actually Captain Jack Sparrow didn't get cursed when his old crew found the Aztec gold. What you may be thinking of is the point in the movie where Jack becomes undead for short time. In the cave, while Barbossa and Jack negotiated, Jack stole one Aztec coin from the chest getting himself cursed until he returned it.