Squirt some light lube into the shifter and work it a bit. It's probably gummed up to the point that the indexing detents are not engaging well. If the lube doesn't help, perhaps it's just worn out.
One thing that I find necessary in diagnosing an indexed shifter is to disconnect the cable from the derailleur and pull it out of the housing. Then, holding hand tension on the cable, I'll run the shifter through it's range. If you feel incremental positive cable movements with no slipping, your problem may be elsewhere..