Fuel gauge works, but not in dash

If the gauge moves at all there is some current passing through it.
It is possible that the actual fault is in the senders current path. First the wire from gauge to sender must be good then the continuity though that sender and to chassis ground must be good. More than a few times a rusty ground jumper ( on the fuel line at the sender ) has caused gauge operation to come and go. Previous threads read "My fuel gauge works fine until it rains" or just the opposite, "Hit a large puddle and the fuel gauge suddenly started working".
I mentioned the loose circuit board pin due it this being the most common fault location. It doesn't rule out those less common fault locations. I wouldn't rework the entire inst panel for a fault in 1 wire/path.