After more than two years of debate, the House and Senate yesterday approved legislation which would give the president control over exports of sensitive high-technology goods and other products with military uses sought by Soviet-bloc countries.

Both houses of Congress approved by voice votes a four-year extension of the 1979 Export Administration Act. President Reagan is expected to sign the measure.

"The House correctly clamped down on the tip of the export pyramid and left alone the rest," said Rep. Toby Roth (R-Wis.). "Our citizens can be assured their technological ingenuity won't show up in Soviet missiles, and our businesses can be assured their exports won't be held up by mounds of paperwork."

"The bill reflects a firm commitment by Congress to close the U.S. high-technology supermarket to the Soviet Union," Roth said.

"It has been a very long and hard-fought struggle to get this bill and move this bill through the legislative process," Sen. John Heinz (R-Pa.) told the Senate yesterday. Passage of the bill ended "innumerable, interminable" negotiations, Heinz said.

The bill was held up last year when provisions to block investments in South Africa were added. In addition, there was extended debate on whether to increase the powers of the Secretary of Defense in controlling exports. Both provisions were dropped from the bill.

Other major conflicts were between the government and businesses, which complained that if they were not allowed to sell high-technology goods to the Soviet-bloc countries, other nations would do so and their exports, already sagging from a high-valued dollar, would continue to slide.

The administration pushed for fast action on the bill this year when businesses threatened to file lawsuits to limit President Reagan's powers to control the flow of some high-technology goods to communist countries.

Defense Department experts contended that export controls should not be loosened because the Soviets' access to western high technology would help them militarily.

Other conflicts were between the Commerce Department, which is interested in promoting exports, and the Pentagon and the U.S. Customs Service, which are concerned with controlling exports.

Rep. Don L. Bonker (D-Wash.) who worked on the bill, said that he and some business people believe that the Defense Department will try to maintain authority over shipments of some exports, although Congress rolled back some of those powers.

"Congress has significantly reformed the Export Administration Act to make it possible for U.S. exporters to compete more equally and effectively," Bonker said. "At the same time, I'm concerned that the administration will not fully implement these reforms."

"Anyone who has followed the export control issue knows the DOD has a record of taking a hard line on what can be exported and what cannot be exported," Bonker said.

A major provision of the act would protect all U.S. export contracts from disruption by future foreign policy export controls except in cases of national emergencies. The act would also speed licensing of all exports to U.S. allies and eliminate licensing requirements for low-technology items to those allies.

The act would also eliminate U.S. restrictions on exports of items that are freely available overseas. It would also automatically end any agricultural export embargo unless it is approved by Congress within 60 days.

American violators of national security export controls would also be subject to tougher penalties, and the government would have authority to restrict imports of foreign violators of U.S. export controls if such action is approved by allies.

The U.S. Customs and Commerce Department would receive added enforcement authority to deter and investigate violations. Defense Department authority would basically remain the same.

When considering new foreign policy export controls, the availability of comparable goods overseas would have to be considered, according to the act.