Cook spaghetti according to package directions; drain and set aside.
Sauté onion and mushrooms in butter until tender. Add flour, salt, pepper, and garlic salt; stir well. Cook 1 minute, stirring constantly. Gradually add milk and half-and-half; cook over medium heat, stirring constantly, until thickened and bubbly. Set aside.
Toss spaghetti with 1/2 cup Parmesan cheese. Spoon spaghetti mixture into a lightly greased 2 1/2-quart shallow baking dish. Pour a layer of sauce mixture over spaghetti. Add 1 cup ham; repeat layers, ending with a layer of sauce. Sprinkle remaining Parmesan cheese and breadcrumbs over top. Bake at 350° for 25 minutes.