It is highly likely that it is the solenoid which is the problem. I had the same problem on my John Deere a couple of weeks ago and it turned out it was a bad solenoid. Do the test which reynoldston suggested, you will probably find it is the solenoid which is causing the problem.