Sounds like you've got bacterial wilt. There are no chemical controls for the wilt. Remove and destroy (don't compost) infected plants immediately. Otherwise, you'll infect other plants.
Bacterial wilt is spread by the striped or spotted cucumber beetle. You can control the beetles with spray early in the season, but barrier control, such as a spun-bonded floating row cover, is often more effective. You also can plant resistant varieties of squash and cucumbers.