It sounds (pun intended) there is an intermittent connection in your cable. One of the connections at either plug might be loose, or there may be a break in the wire of the cable itself.
If there's a warranty on the cables you should take 'em back. Otherwise, you'll have to either pay a tech to fix the problem, or try to do it yourself.
Its unlikely that more than one cable is giving trouble, but still, it shouldn't be your problem!