Open the old door and drive the hinge pins up and out of the hinges, by striking a screwdriver with a hammer. Remove the screws holding the hinge pieces to the insides of the doorjamb.
Cut through the seams at the edges of the door’s trim pieces, using a utility knife. Insert a wide pry bar under the trim and gently rock the bar back and forth to pull the trim off the wall. Remove the trim from the bottom of the walls on either side of the doorway, using the pry bar.
Pry out the nails holding the doorjamb to the studs, using a hammer’s claw, and then pull out the entire doorjamb from the doorway. Measure the width of the pocket door, and draw the same measurement on the wall next to the doorway, both at the level of the top and bottom of the doorway. Use a carpenter’s square to ensure the lines sit level.
Connect the two lines you drew on the wall with a single vertical line. Cut through the drywall, along the lines you drew, with a drywall saw. Pull off the drywall from the area you cut.
Cut through the wall studs at the edges of the cutout, using a reciprocating saw. Measure the width of the doorway plus the cutout you made in the wall, and cut a 2-by-4 to fit. Install the 2-by-4 at the top of the doorway and cutout, and drive nails through the board and into the wall studs.
Cut the pocket door’s track so it measures the same length as the door’s width, using a handsaw to make the cut. Hold the flat side of the track against the 2-by-4 you nailed to the top of the cutout, and drive wood screws through the mounting holes on either end of the track, anchoring it to the studs.
Position the split studs’ brackets on the floor inside the cutout, spacing them 6 inches apart from each other. Drive wood screws through the mounting holes in the brackets.
Insert one end of the split studs into the receivers at the top of the brackets, and then swing the split studs until they touch the 2-by-4 at the top of the cutout. Drive nails through the tops of the split studs, at an angle, and into the 2-by-4.
Hold the door at the end of the track in the cutout, and slide the wheels at the top of the door onto the track. Cut drywall sheets to cover the cutout on both sides, driving screws through the perimeter of the sheets and into the wall studs.
Cover all the drywall joints with drywall tape. Apply drywall compound to the joints and the screw heads, using a putty knife. Allow the compound to dry before applying another coat. Sand the compound until smooth, after it has dried, using fine-grit sandpaper.