Help me please?

I have a 2002 Silverado Ex. Cab Z 71 with 19,200 miles on it. Obviously, I don't drive it a lot.
Saturday, I started the truck in my garage and put it in gear. The engine started and immediately quit.

I started it several times and it would start right up, but would not idle, either in gear or in neutral.

If I accellerated, it would run and drive, but it would die if I took my foot off the gas.

Also, I noticed that when I filled it up with gas, the mpg had deteriorated from 15-17 to 12-13.

While trying to determine where to go to get this checked, I decided to replace the fuel filter, even though the current filter had been put on 3000 miles ago.

Surprise! I started the truck to get it outside to work on it and the thing ran fine.

I went ahead and changed the fuel filter, but I am worried that this will happen again.

Has this happened to anyone else? Any insight into this problem would be very much appreciated.

Thanks in advance.