Removing Prepayments

Hello,

Is there a way to remove prepayments from a sales order, after the payment has been applied, and the period has been closed?  We need to cancel a sales order, apply the payment against a new order.

Many thanks!