To draw off the Confederate cavalry and open the door for a general movement to the James River, Maj. Gen. Philip Sheridan mounted a large-scale cavalry raid into Louisa County, threatening to cut the Virginia Central Railroad. On June 11, Sheridan with the Gregg's and Torbert's divisions attacked Hampton's and Fitzhugh Lee's cavalry divisions at Trevilian Station. Sheridan drove a wedge between the Confederate divisions, throwing them into confusion. On the 12th, fortunes were reversed. Hampton and Lee dismounted their troopers and drew a defensive line across the railroad and the road to Gordonsville. From this advantageous position, they beat back several determined dismounted assaults. Sheridan withdrew after destroying about six miles of the Virginia Central Railroad. Confederate victory at Trevilian prevented Sheridan from reaching Charlottesville and cooperating with Hunter's army in the Valley. This was one of the bloodiest cavalry battles of the war.