I'm aware of this question but it hasn't really come to any solid conclusion. Additionally, that question is more concerned about spell stacking in general, and I'm interested in this specific case.
So imagine that you've just defeated the BBEG, and you and your party wade hip-deep into the overflowing treasure room. After sorting it all out, you've found a fabulous magical weapon, with all of the enchantments you've been hoping for. It's perfect!
...except the random treasure generator rolled it up as a Ranseur.
"A what? Is that even a thing?"
"It's a thing. It's a polearm."
"I've never heard of it."
"It's right there in the PHB, next to the Lance."
And so on, back and forth with the DM, and you Google it because nobody else knows what it is either, and you look at the stats, and you realize... this is not the weapon you wanted.
But you're a party of high powered adventurers, and you're not about to let this set you back! You turn to the mage...
So. You have a magic weapon, and for whatever reason, it would be just that much nicer if it were a different type of magic weapon.
Polymorph Any Object
Magic items aren't affected by this spell.
Well drat. But...
Dispel Magic
Targeted Dispel: If you succeed ... A suppressed item becomes nonmagical for the duration of the effect.
Well this is great! It's a nonmagical item now! (For a few moments, anyway.) We quickly follow that Dispel up with a Polymorph Any, and bam! A shiny new longsword! We just wait a few moments...
And this is where it gets confusing.
So, what happens to a magical weapon that has been dispelled and then polymorphed, once the dispel expires?
The simple solution: The magic comes back, and tada, an amazing magical [whatever]!
The "it never happened" solution: The Universe (aka DM) can see what you're trying to pull, you sneaky bugger, and the Polymorph won't take in the first place.
The "self-retconning" solution: The magic weapon, now being a magic item, cannot be affected by Polymorph Any and reverts back to its original shape.
The "it only works for a while" solution: (If the DM rules a non-permanent duration for the Polymorph) It appears to work for a while, but after a time the Polymorph expires and it reverts to the original shape.
The "you done mucked it up now!" solution: You broke everything! The new weapon is not the same as the dispelled weapon. The enchantments were bound to a weapon that no longer exists, and so have nowhere to return to. They evaporate into the Aether, and you are left with a completely mundane weapon (and a very sad party).
Or some other outcome I haven't considered?
Obviously a RAW answer would be best, or a "Word of God" style ruling.
If you can't find RAW, which of the above options would you rule for at your table, and why?