How can I make to close positions on EA as loss target

 

Hi, I want my EA to close all position that its opens with loss target. I know there is profit target but is there loss taget can close all positions? what is the code ? thanks.

Reason: