You can now move miles between CO and UA accounts by linking the accounts, so you should be able to apply your CO miles to a UA upgrade by doing this.
That's a good question about refunding the ELR fee if you get upgraded. I don't have any experience with this as I get ELR for free. Presumable, if you aren't sitting in an ELR seat anymore then you should get refunded.