hide fied based on the selection of other fields

Hai steve and friends;
I am trying to hide some of my fields upon selection of select item in some other field. i.e
suppose i have a field consumable type if some one select paper he should see only type of paper after that, if he select cartridge then he should see the printer model and
cartridge number field.
i have tried using java but not able to do it. Please some body guide through the piece of code to do this.
thanks in advance.
samhans
I am trying to hide some of my fields upon selection of select item in some other field. i.e
suppose i have a field consumable type if some one select paper he should see only type of paper after that, if he select cartridge then he should see the printer model and
cartridge number field.
i have tried using java but not able to do it. Please some body guide through the piece of code to do this.
thanks in advance.
samhans