Conditions are the only standard effect that require damage to be applied. All other Surge effects don't need you to deal damage in order to work (other than those that specify needing damage)
If the X is rolled this is a miss, no surges can be used.
In case of a ranged attack that does not have enough range, surges can be used to apply +range. If after that the range is still not sufficient, that attack counts as a miss and no further surges can be spent.
In all other cases surges can be spent to recover fatigue or get rid of a condition on yourself.