Hello, John
It's simply not uncommon for a speedometer/odometer to fail in this way with age.
I have encountered these symptoms in the past (with Mercedes odometers of similar vintage, which may or may not be internally similar to your Audi odometer) and typically, what happens is that the speedometer cable drives both the speedometer needle and via gearing internal to the unit, also the odometer. What I, and others have seen (once again, my experience is with Benz units) is that the gear which drives the odometer numbers either breaks with age or wears out at the point of its press-fit on the shaft holding the numbers, and although you get a speed reading, you no longer get a distance reading.
Our Audi 5000 manual
http://www.bentleypublishers.com/audi/5000/1984-1988/Audi-5000-84-88-Factory-Repair-Manual.html has an exploded-view diagram in volume 2 that shows instrument cluster assembly, and covers removal and installation. Complete odometer diagnosis and rebuild is not something that is generally a part of original factory information. In cases of odometer failure, the official word is to replace the unit, not repair it.
That being said, different vehicle enthusiasts sometimes have luck figuring out odometer fixes. But, unfortunately, I personally know of no further resource to recommend to you for your Audi 5000.
Rick W
Bentley Publishers