crazy i got the same problem..
on my 240 the plug in for the headlight was bad.. like bent so many times it coulendt make a connection..
check the female end that goes to the male end of the bulb on your headlight..

you like my 2 minute paint job
and on my fog light i just found a spot where i must of hit something and cut the wire a little and everytime it got wet it blew the bulb