Head and dash board lights flicker on 2005 GMC Sierra 1500

I just bought a 2005 GMC Sierra and the head light (low beam) and dash board lights flicker. They don't seem to do it when i'm sitting still only when driving.

Asked by for the 2005 GMC Sierra 1500
Now all you have to do is find the loose wire/connection causing this, likely at the headlight switch. May have a pushed out spade connector that did not slide inside each other when plugged in.