Thank you for you reply. I will try to describe the situation in more detail. When I bought the truck the transmission was locked up meaning when you dropped it into gear it would kill the engine, the guy said he had been driving it and parked it in his driveway and went back later to drive it and it stalled every time he put it in gear. I had it towed home and I was laying underneath it and moved the tv cable back and forth by hand, then the truck was able to move.
After driving it a while I pulled in my driveway and it did the same thing. So I decided to pull the pan and found a broken band anchor. I replaced the anchor and band strut with aftermarket and while I had the valve body out I replaced all the electronics. If I make a short drive the truck is normal when I get back, if I make a longer drive when I get back to the driveway and stop, it’s like your power braking it and after you put it in park or neutral and drop it back in gear it stalls.
I let it sit a couple hours without touching it and tried it again and it was still locked up. Then with the key off I mashed the throttle 4 or 5 times then started it up and put it in gear and it was fine. So I’m not sure if something in the valve body is sticking when it’s hot or is it electrical.
The check engine light has never been on during any of this, and yes I checked to make sure it works. Is The wire your referring the ground wire?