Thank you for helping me out with that one. Pretty simple problem now after reading about the ANSELH in the datasheet though... But its nice to get some help when you are banging the head...
I am learning new stuff all the time and I think the PIC processor is great. I work as a teacher in high school and we have been using Basic Stamp wich is a bit easier to work with but have limitations. (Especially the price !!) One of my students made code for a tachometer using BS2 and I promised him to port the program to a cheaper PIC processor. I managed to get the tachometer running now on a PIC16F628 that costs a fraction of the BS2. I hope my student will be pleased.
Thanks again.