I have numbers in cells and I am trying to add them up if they meet a certain criteria. Say for example I have sales numbers like
$500
$5000
$200
$2000
and I want to give $50 commision if sales is <$1000, but 5% if >$1000 how would I go about that..

So for example I should get a total of $450..($50+$250+$50+$100) for the above figures using the excel formula.

Thanks.