Lube the chain if you haven't already and check for stiff links.
Then check the inner cable moves without snagging. I recent had a very similar problem on my '99 East Peak, changing gears on the bike stand was fine, but when putting the power on, the chain skipped all over the cassette.
I removed and cleaned everything, still no joy, so I replaced the Gear Cable, and that solved it.
Sometimes it can be as simple as the inner cable snagging on the end of the outer cable, or the outer being bunged-up with grease/dirt.