A couple of my clients have experienced an interesting issue lately. Purchase order are tied to sales documents that are already moved to history. This puts the purchase order in a limbo state where it cannot be closed or cancelled. I don't know for sure the exact sequence of events that causes this but here is how it can be resolved:
1. Delete the records in the SOP60100 table related to the offending purchase number. (Standard disclaimer about modifying SQL data applies here. If you are unfamiliar with SQL queries and/or Dynamics GP table structure, please call your partner for assistance.)
2. Reconcile the offending purchase order number.
3. Edit the purchase order and change the status to Cancelled.