Narrative:

VMC day, off of runway 25R of lax on the gmn departure. Climbing to 9000 ft, autoplt off, flight directors off, autothrottle off, out of 3000 ft right turn to 300 degrees and looking for traffic (a turboprop). Reported in sight then continued turn to 020 degrees, climbing through 8000 ft, ATC called another target at 12 O'clock position and reported it in sight. First officer could not see new target. I looked out and when I scanned back, discovered that I had gone through my assigned heading by 20 degrees. Started to correct back to the assigned heading when ATC again called traffic at 12 O'clock position. Looked out, and when scanned back, discovered I was climbing through 8900 ft for 9000 ft assigned. Started leveloff, but achieved a maximum of 9300 before returning to 9000 ft. I think the obvious reason for this altitude deviation is the distraction caused by the perceived need to acquire the traffic called by ATC, along with task overloading caused by hand flying the departure.

Google
 

Original NASA ASRS Text

Title: B767 CAPT HAD AN ALT OVERSHOOT AND A TRACK DEV WHILE HAND FLYING THE ACFT, AFTER THE CTLR POINTED OUT TFC AHEAD.

Narrative: VMC DAY, OFF OF RWY 25R OF LAX ON THE GMN DEP. CLBING TO 9000 FT, AUTOPLT OFF, FLT DIRECTORS OFF, AUTOTHROTTLE OFF, OUT OF 3000 FT R TURN TO 300 DEGS AND LOOKING FOR TFC (A TURBOPROP). RPTED IN SIGHT THEN CONTINUED TURN TO 020 DEGS, CLBING THROUGH 8000 FT, ATC CALLED ANOTHER TARGET AT 12 O'CLOCK POS AND RPTED IT IN SIGHT. FO COULD NOT SEE NEW TARGET. I LOOKED OUT AND WHEN I SCANNED BACK, DISCOVERED THAT I HAD GONE THROUGH MY ASSIGNED HDG BY 20 DEGS. STARTED TO CORRECT BACK TO THE ASSIGNED HDG WHEN ATC AGAIN CALLED TFC AT 12 O'CLOCK POS. LOOKED OUT, AND WHEN SCANNED BACK, DISCOVERED I WAS CLBING THROUGH 8900 FT FOR 9000 FT ASSIGNED. STARTED LEVELOFF, BUT ACHIEVED A MAX OF 9300 BEFORE RETURNING TO 9000 FT. I THINK THE OBVIOUS REASON FOR THIS ALTDEV IS THE DISTR CAUSED BY THE PERCEIVED NEED TO ACQUIRE THE TFC CALLED BY ATC, ALONG WITH TASK OVERLOADING CAUSED BY HAND FLYING THE DEP.

Data retrieved from NASA's ASRS site as of July 2007 and automatically converted to unabbreviated mixed upper/lowercase text. This report is for informational purposes with no guarantee of accuracy. See NASA's ASRS site for official report.