Well, say you went into Bob's Gun Store and asked if you could trade the 23 for a 26 (good call BTW).
More than likely you'll be turned down as the GS won't be making any profit on the deal, unless it will be *toward* the purchase of another in the case, just like a used car. That $500 Glock will then be worth $300 in trade-in, if that.
So that's $200 you're out. If the deal is set, the GS employee will need to start the regular gun buying process just like any other purchase. Tax, NICS check fee etc etc.
Or...you can find a LOCAL person to simply trade your 23 for a 26 if they're so inclined. No fees, no paperwork, both parties just have to be the same state residency status. Low probability of that happening though.