"The sudden collapse of squash vines is usually caused by an insect called the squash vine borer. Other possible causes are bacterial wilt or root damage caused by cucumber beetle larvae.
If borers are involved, you should be able to see a small hole in the main stem near the base of the plant. You may also see frass coming out of the hole. If you slit the stem lengthwise, you may find a grublike larva inside the stem. You can kill the larva and mound soil around the slit stem. This may save a wilting plant if the wilt hasn't progressed too far. You can prevent the adult from laying its eggs on the stem by covering the stems with a barrier such as a nylon stocking, or cover the entire plant with floating row cover so the adult moth can't get to the stem.
Chemical controls must be done as a preventative. Once the larvae are inside the stem, most chemicals will be ineffective. Rotenone, pyrethrum, malathion or sevin are effective if applied every 7 to 10 days when squash vines begin to run."